Vehicle imaging device, image processing method, and image processing program

ABSTRACT

A measurement unit measures a first generation time of a first vanishing point of a plurality of radially diverging motion vectors generated in a front image region and a second generation time of a second vanishing point of a plurality of converging motion vectors generated in the front image region within a predetermined period of time in a state in which an image rotation unit adjusts positions of the front image region and a rear image region in a circumferential direction. The image rotation unit keeps the positions of the front image region and the rear image region in the circumferential direction when the first generation time measured by the measurement unit is longer than the second generation time, and rotates the captured image to reverse the front image region and the rear image region when the first generation time is not longer than the second generation time.

BACKGROUND

The present disclosure relates to a vehicle imaging device, an imageprocessing method, and an image processing program for imaging subjectsthrough 360 degrees on the front, rear, right, and left sides around avehicle using a fisheye lens.

Japanese Unexamined Patent Application Publication No. 2018-195348discloses a vehicle imaging device (called a drive recorder) for imagingsubjects through 360 degrees on the front, rear, right, and left sidesaround a vehicle using a fisheye lens.

SUMMARY

The vehicle imaging device as described above analyzes a 360-degreecaptured image to determine the front and rear sides of the vehicle, andextracts regional images corresponding to a front image region, a rearimage region, and right and left side image regions. The conventionalvehicle imaging device sometimes makes an error in determination on thefront and rear sides of the vehicle, which leads to a wrong extractionof the respective regional images.

A first aspect of one or more embodiments provides a vehicle imagingdevice provided in a vehicle, the device including: a motion vectordetector configured to detect motion vectors of a captured image of asubject imaged through 360 degrees by an imaging unit to which a lightenters via a fisheye lens; a front-rear-right-left determination unitconfigured to determine front and rear sides and right and left sides ofthe vehicle in accordance with the captured image and determinepositions of at least a front image region and a rear image region in acircumferential direction in the captured image; an image rotation unitconfigured to rotate the captured image about a first vanishing point ofa plurality of radially diverging motion vectors among the motionvectors detected by the motion vector detector immediately after thevehicle starts moving, and adjust the positions of the front imageregion and the rear image region in the circumferential direction; and ameasurement unit configured to measure a first generation time of thefirst vanishing point generated in the front image region and a secondgeneration time of a second vanishing point of a plurality of convergingmotion vectors generated in the front image region within apredetermined period of time in a state in which the image rotation unitadjusts the positions of the front image region and the rear imageregion in the circumferential direction, wherein the image rotation unitis configured to keep the positions of the front image region and therear image region in the circumferential direction when the firstgeneration time measured by the measurement unit is longer than thesecond generation time, and rotate the captured image to reverse thefront image region and the rear image region when the first generationtime is not longer than the second generation time, the vehicle imagingdevice further comprises an image extraction unit configured to extractregional images of the front image region and the rear image region keptor reversed by the image rotation unit in the captured image to generatea front image and a rear image.

A second aspect of one or more embodiments provides an image processingmethod for a vehicle imaging device provided in a vehicle, the methodincluding: detecting motion vectors of a captured image of a subjectimaged through 360 degrees by an imaging unit to which a light entersvia a fisheye lens; determining front and rear sides and right and leftsides of the vehicle in accordance with the captured image anddetermining positions of at least a front image region and a rear imageregion in a circumferential direction in the captured image; rotatingthe captured image about a first vanishing point of a plurality ofradially diverging motion vectors among the motion vectors detectedimmediately after the vehicle starts moving, and adjusting the positionsof the front image region and the rear image region in thecircumferential direction; measuring a first generation time of thefirst vanishing point generated in the front image region and a secondgeneration time of a second vanishing point of a plurality of convergingmotion vectors generated in the front image region within apredetermined period of time in a state of adjusting the positions ofthe front image region and the rear image region in the circumferentialdirection; keeping the positions of the front image region and the rearimage region in the circumferential direction when the first generationtime measured is longer than the second generation time; rotating thecaptured image to reverse the front image region and the rear imageregion when the first generation time measured is not longer than thesecond generation time; and extracting regional images of the frontimage region and the rear image region kept when the first generationtime measured is longer than the second generation time or reversed whenthe first generation time measured is not longer than the secondgeneration time in the captured image to generate a front image and arear image.

A third aspect of one or more embodiments provides an image processingprogram stored in a non-transitory storage medium causing a computerinstalled in a vehicle imaging device provided in a vehicle to executethe steps of: detecting motion vectors of a captured image of a subjectimaged through 360 degrees by an imaging unit to which a light entersvia a fisheye lens; determining front and rear sides and right and leftsides of the vehicle in accordance with the captured image anddetermining positions of at least a front image region and a rear imageregion in a circumferential direction in the captured image; rotatingthe captured image about a first vanishing point of a plurality ofradially diverging motion vectors among the motion vectors detectedimmediately after the vehicle starts moving, and adjusting the positionsof the front image region and the rear image region in thecircumferential direction; measuring a first generation time of thefirst vanishing point generated in the front image region and a secondgeneration time of a second vanishing point of a plurality of convergingmotion vectors generated in the front image region within apredetermined period of time in a state of adjusting the positions ofthe front image region and the rear image region in the circumferentialdirection; keeping the positions of the front image region and the rearimage region in the circumferential direction when the first generationtime measured is longer than the second generation time; rotating thecaptured image to reverse the front image region and the rear imageregion when the first generation time measured is not longer than thesecond generation time; and extracting regional images of the frontimage region and the rear image region kept when the first generationtime measured is longer than the second generation time or reversed whenthe first generation time measured is not longer than the secondgeneration time in the captured image to generate a front image and arear image.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a perspective view showing an example of a vehicle equipped ina compartment with a vehicle imaging device according to eachembodiment.

FIG. 2 is a block diagram showing a specific configuration example ofthe vehicle imaging device according to each embodiment.

FIG. 3 is a schematic view showing a 360-degree captured image generatedby an imaging unit of the vehicle imaging device according to eachembodiment, and showing a state of correctly determining the forwarddirection of the vehicle.

FIG. 4 is a schematic view showing the 360-degree captured imagegenerated by the imaging unit of the vehicle imaging device according toeach embodiment, and showing an example of a state of wronglydetermining the forward direction of the vehicle.

FIG. 5A is a view showing an example of a front image in the state ofwrongly determining the forward direction of the vehicle as illustratedin FIG. 4.

FIG. 5B is a view showing an example of a rear image in the state ofwrongly determining the forward direction of the vehicle as illustratedin FIG. 4.

FIG. 5C is a view showing an example of a right-side image in the stateof wrongly determining the forward direction of the vehicle asillustrated in FIG. 4.

FIG. 5D is a view showing an example of a left-side image in the stateof wrongly determining the forward direction of the vehicle asillustrated in FIG. 4.

FIG. 6 is a view showing motion vectors detected in the front image, therear image, the right-side image, and the left-side image in the stateof correctly determining the forward direction of the vehicle asillustrated in FIG. 3.

FIG. 7 is a view showing motion vectors detected in the front image, therear image, the right-side image, and left-side image in the state ofwrongly determining the forward direction of the vehicle as illustratedin FIG. 4.

FIG. 8 is a flowchart showing a process of processing executed in afirst embodiment.

FIG. 9 is a flowchart showing the process of processing executed in afirst embodiment continued from the processing of the flowchart shown inFIG. 8.

FIG. 10A is a view showing an example of a front image in a state afterthe direction of the front image is adjusted to conform to the forwarddirection of the vehicle.

FIG. 10B is a view showing an example of a rear image in the state afterthe direction of the front image is adjusted to conform to the forwarddirection of the vehicle.

FIG. 10C is a view showing an example of a right-side image in the stateafter the direction of the front image is adjusted to conform to theforward direction of the vehicle.

FIG. 10D is a view showing an example of a left-side image in the stateafter the direction of the front image is adjusted to conform to theforward direction of the vehicle.

FIG. 11 is a schematic view showing a blur of an image of a subject in aright-side image or a left-side image in a vehicle imaging deviceaccording to a second embodiment.

FIG. 12 a schematic view showing a state in which the blur of the imageof the subject in the right-side image or the left-side image has beencorrected in the vehicle imaging device according to a secondembodiment.

FIG. 13 is a flowchart showing a process of processing executed in asecond embodiment.

FIG. 14A is a view showing an example of a right-side image in whichplural motion vectors in different directions are detected in a vehicleimaging device according to a third embodiment.

FIG. 14B is a view showing an example of a left-side image in which asingle motion vector is detected in the vehicle imaging device accordingto a third embodiment.

FIG. 15 is a flowchart showing a process of processing executed in athird embodiment.

FIG. 16 is a schematic view showing plural vehicles irradiated withsunlight in a direction indicated by the solid-white arrow in a state inwhich the vehicles are traveling ahead of and behind the host vehicleand the vehicles are traveling in the lanes on the right and left sidesof the lane in which the host vehicle is traveling.

FIG. 17 is a view showing a state in which an incident direction of thesunlight is divided into eight in a fourth embodiment.

FIG. 18A is a flowchart showing a part of processing executed in afourth embodiment.

FIG. 18B is a flowchart showing a part of the processing executed in afourth embodiment continued from the processing shown in FIG. 18A.

FIG. 19 is a schematic view showing a state of the vehicle when reachinga tunnel, entering the tunnel, traveling in the tunnel, and coming outof the tunnel.

FIG. 20A is a flowchart showing a part of processing executed in a fifthembodiment.

FIG. 20B is a flowchart showing a part of the processing executed in afifth embodiment continued from the processing shown in FIG. 20A.

FIG. 21 is a block diagram showing a specific configuration example of avehicle imaging device according to a sixth embodiment.

FIG. 22 is a flowchart showing a process of processing executed in asixth embodiment.

FIG. 23 is a schematic view showing an instrument panel region and anon-instrument panel region defined in an in-vehicle image regionaccording to a seventh embodiment.

FIG. 24 is a flowchart showing a process of processing executed in aseventh embodiment.

FIG. 25 is a schematic view showing a first exposure time whengenerating a long-period exposure image and a second exposure time whengenerating a short-period exposure image.

DETAILED DESCRIPTION

Hereinafter, a vehicle imaging device, an image processing method, andan image processing program according to each embodiment will bedescribed with reference to the accompanying drawings.

First Embodiment

As illustrated in FIG. 1, a vehicle imaging device 100 is installed atau upper part of a front shield 201 of a vehicle 200. The vehicleimaging device 100 is a drive recorder. The installation position of thevehicle imaging device 100 is not limited to the front shield 201. Thevehicle imaging device 100 includes a fisheye lens 11 that capturesimages through 360 degrees on the front, rear, right, and left sides ofthe vehicle 200 including an image of a compartment as viewed fromabove.

FIG. 2 is a view showing a specific configuration example of the vehicleimaging device 100. The vehicle imaging device 100 includes the fisheyelens 11, an imaging unit 12, an image processing unit 13, an imageanalyzer 14, a communication unit 15, a controller 16, a recordreproduction unit 17, and a monitor 18. The imaging unit 12 to themonitor 18 are connected to each other via a bus 19.

The image processing unit 13 includes an image rotation unit 131, animage extraction unit 132, and a high-dynamic-range image compositionunit 133. The term “high-dynamic-range” is abbreviated below to “HDR”.The image analyzer 14 includes a motion vector detector 141 and afront-rear-right-left determination unit 142. The controller 16 includesa measurement unit 161. The record reproduction unit 17 includes aremovable memory card 170 as a recording medium (a storage medium). Therecording medium is not limited to the memory card.

The imaging unit 12 includes an imaging element which is a chargecoupled device (CCD) or a complementary metal oxide semiconductor(CMOS). The imaging unit 12 generates a captured image (an all-aroundimage) of a subject imaged through 360 degrees with an incident lightindicated by the one-dash chain line in FIG. 2 entering from the subjectvia the fisheye lens.

In a case in which the vehicle imaging device 100 generates a capturedimage with 60 frames/second, the imaging unit 12 images a subject with120 frames/second. The imaging unit 12 exposes one of the two framesadjacent to each other for a first exposure time (a long period), andexposes the other frame for a second exposure time (a short period)shorter than the first exposure time. The imaging unit 12 includes anelectronic shutter, so as to optionally vary the exposure time accordingthe control by the controller 16. The imaging unit 12 generates along-period exposure image and a short-period exposure image as a360-degree captured image.

The respective 360-degree long-period exposure image and short-periodexposure image generated by the imaging unit 12 are supplied to theimage processing unit 13 and the image analyzer 14.

As schematically illustrated in FIG. 3, the 360-degree captured imagegenerated by the imaging unit 12 is composed of a circular pixel regionas a part of a rectangular pixel region of the imaging element. Thecaptured image composed of the circular pixel region includes anin-vehicle image region as viewed from above the compartment of thevehicle 200, and a front image region, a rear image region, a right-sideimage region, and a left-side image region around the in-vehicle imageregion. Since the 360-degree captured image is obtained such that asubject is imaged via the fisheye lens 11, the images in the front imageregion, the rear image region, the right-side image region, and theleft-side image region are greatly distorted.

The positions of the front image region, the rear image region, theright-side image region, and the left-side image region in thecircumferential direction as illustrated in FIG. 3 are an example forillustration purposes. The determination of which direction in thecircumferential direction is set to the front image region, the rearimage region, the right-side image region, or the left-side image regionis finally made in accordance with motion vectors detected by the motionvector detector 141 and the determination made by thefront-rear-right-left determination unit 142. The front image regionillustrated in FIG. 3 is presumed to be an image in a state in which theforward direction of the vehicle 200 is correctly determined and is thusthe actual forward direction as indicated by the rectangle of the dashedline corresponding to the direction in which the front shield 201 of thevehicle 200 is located.

When the vehicle imaging device 100 is activated, the HDR imagecomposition unit 133 combines the respective 360-degree images of thelong-period exposure image and the short-period exposure image togenerate a combined image (a HDR combined image) with 60 frames/secondin which the dynamic range is expanded. The HDR image composition unit133 combines the long-period exposure image and the short-periodexposure image in a predetermined ratio depending on the brightness ofthe image analyzed by the image analyzer 14 in accordance with thecontrol by the controller 16. The HDR image composition unit 133,however, is not necessarily used in a first embodiment.

The front-rear-right-left determination unit 142 determines the frontand rear sides and the right and left sides of the vehicle 200 based onthe combined image generated by the HDR image composition unit 133 inaccordance with the control by the controller 16, and provisionallydetermines the positions of the front image region, the rear imageregion, the right-side image region, and the left-side image region inthe circumferential direction. The reason for the provisionaldetermination of the positions in the front, rear, right, and leftdirections is that the front, rear, right, and left directions can becorrected by the processing described below.

The front-rear-right-left determination unit 142 determines the forwarddirection of the vehicle 200 based on an image of a steering wheel 202of the vehicle 200, for example. The state of the image of the steeringwheel 202, however, can vary depending on the mount position, the mountangle, and the direction of the vehicle imaging device 100. The term“mount position” refers to a position at which the vehicle imagingdevice 100 is arranged either ahead of the steering wheel 202 or behindthe steering wheel 202. The term “mount angle” refers to an angle atwhich the imaging center of the vehicle imaging device 100 makes withrespect to the vertical direction. The term “direction” refers to adirection in which the vehicle imaging device 100 is directed in thecircumferential direction.

The front-rear-right-left determination unit 142 would make a wrongdetermination regarding the forward direction of the vehicle 200depending on the image of the steering wheel 202. Thefront-rear-right-left determination unit 142 may determine the forwarddirection of the vehicle 200 in accordance with an image other than thesteering wheel 202 of the vehicle 200. The front-rear-right-leftdetermination unit 142, however, still could make a wrong determinationregarding the forward direction of the vehicle 200.

A case is assumed in which the front-rear-right-left determination unit142 wrongly determines, as the forward direction, a direction deviatingby a predetermined angle in the leftward direction from the travelingdirection of the vehicle 200, as illustrated in FIG. 4. If thefront-rear-right-left determination unit 142 having determined the wrongforward direction determines the positions of the front image region,the rear image region, the right-side image region, and the left-sideimage region in the circumferential direction, the front image regiondoes not conform to the image showing the actual forward direction ofthe vehicle 200 as indicated by the rectangle of the dashed line.

FIG. 4 illustrates the case in which the front image region deviates bya predetermined angle in the leftward direction from the travelingdirection of the vehicle 200. The front-rear-right-left determinationunit 142 could wrongly determine the rear side as the front side, ordetermine the right side or the left side as the front side depending onthe mount position of the vehicle imaging device 100, making a wrongdetermination regarding the front image region as a position in thecircumferential direction completely different from the front side ofthe vehicle 200.

The image rotation unit 131 of the image processing unit 13 can rotatethe 360-degree image in accordance with the control by the controller 16as described below. The image extraction unit 132 extracts therespective regional images based on the positions of the front imageregion, the rear image region, the right-side image region, and theleft-side image region in the circumferential direction determined bythe front-rear-right-left determination unit 142 in accordance with thecontrol by the controller 16. The image extraction unit 132 corrects thedistortion greatly caused by the fisheye lens 11 in the extractedregional images of the front image region, the rear image region, theright-side image region, and the left-side image region, so as toapproximate the view on the respective front, rear, right, and leftsides of the vehicle 200 that the person is presumed to actually see.

FIG. 5A to FIG. 5D schematically show examples of a front image 20F, arear image 20B, a right-side image 20R, and a left-side image 20Lobtained such that the image extraction unit 132 extracts the respectiveregional images to correct the distortion. FIG. 5A to FIG. 5D are viewseach showing a state in which the front-rear-right-left determinationunit 142 wrongly determines the forward direction deviating by apredetermined angle in the leftward direction from the travelingdirection of the vehicle 200 while the deviation of the angle is notcorrected yet.

As illustrated in FIG. 5A, the front image 20F is displaced toward anA-pillar 203AL on the left side. As illustrated in FIG. 5B, the rearimage 20B includes the driver 300, and is displaced toward the rightside of the vehicle 200. As illustrated in FIG. 5C, the right-side image20R is displaced toward the front side. As illustrated in FIG. 5D, theleft-side image 20L is displaced toward the rear side.

The motion vector detector 141 detects the respective motion vectors inthe front image region, the rear image region, the right-side imageregion, and the left-side image region. The motion vector detector 141detects the respective motion vectors basically in accordance with theshort-period exposure image. The motion vector detector 141 detects therespective motion vectors in accordance with the long-period exposureimage when not being able to or hard to detect the motion vectors inaccordance with the short-period exposure image. The respective motionvectors in the front image region, the rear image region, the right-sideimage region, and the left-side image region are referred to below asMVF, MVB, MVR, and MVL.

FIG. 6 illustrates the respective motion vectors MVF, MVB, MVR, and MVLin a state in which the forward direction of the vehicle 200 iscorrectly determined as illustrated in FIG. 3, and the front image 20Fconforms to the actual forward direction of the vehicle 200. FIG. 6 andFIG. 7 described below illustrate the right-side image 20R and theleft-side image 20L in a state of being rotated by 90 degrees. Themotion vectors MVF in the front image 20F radially diverge about avanishing point Pv1 at which the divergence starts. The motion vectorsMVB in the rear image 20B converge at a vanishing point Pv2. The motionvectors MVR in the right-side image 20R and the motion vectors MVL inthe left-side image 20L are directed from the front side to the rearside.

When the front image 20F conforms to the actual forward direction of thevehicle 200, the vanishing point Pv1 in the front image 20F is locatedsubstantially in the center Hctr in the right-left direction in thefront image 20F.

FIG. 7 illustrates the respective motion vectors MVF, MVB, MVR, and MVLin a state in which the forward direction of the vehicle 200 is wronglydetermined as illustrated in FIG. 4, and the front image 20F deviates bya predetermined angle in the leftward direction from the actual forwarddirection of the vehicle 200. Since the front image 20F does not conformto the actual forward direction of the vehicle 200 but deviates by apredetermined angle in the leftward direction, the vanishing point Pv1in the front image 20F is located on the right side of the substantialcenter Hctr in the right-left direction in the front image 20F.

In the vehicle imaging device 100 according to a first embodiment, theimage rotation unit 131 rotates the 360-degree captured imageillustrated in FIG. 4 in the rightward direction so as to cancel out thedisplacement between the front image 20F and the actual forwarddirection of the vehicle 200 to lead the vanishing point Pv1 to conformto the center Hctr. This processing brings the front image region to astate conforming to the actual forward direction of the vehicle 200 asindicated by the rectangle of the dashed line illustrated in FIG. 3 tolead the front image 20F to show the front side.

The image extraction unit 132 extracts the respective regional images ofthe front image region, the rear image region, the right-side imageregion, and the left-side image region in the state in which thedisplacement between the front image 20F and the actual forwarddirection of the vehicle 200 is canceled out, and generates the frontimage 20F, the rear image 20B, the right-side image 20R, and theleft-side image 20L in which the distortion is corrected.

The front image 20F, the rear image 20B, the right-side image 20R, andthe left-side image 20L after the displacement between the front image20F and the actual forward direction of the vehicle 200 is canceled outlead to the state equivalent to that as illustrated in FIG. 6 in whichthe forward direction of the vehicle 200 is correctly determined.

The present embodiment is illustrated above with the case in which theimage rotation unit 131 cancels out the displacement of the front image20F deviating by a predetermined angle in the leftward direction fromthe traveling direction of the vehicle 200, and the image extractionunit 132 then extracts the respective regional images. As describedabove, the vehicle imaging device 100 could wrongly determine theposition in the circumferential direction as the front image regioncompletely different from the front side of the vehicle 200. Thevanishing point Pv1 in this case is not present in the front image 20Fextracted in accordance with the wrong front image region. The imagerotation unit 131 then rotates the 360-degree captured image, so as tolead the vanishing point Pv1 to conform to the center Hctr in the frontimage 20F if the vanishing point Pv1 is not present in the front image20F.

As described above, the image rotation unit 131 rotates the 360-degreecaptured image to cancel out the displacement between the front image20F and the actual forward direction of the vehicle 200, and the imageextraction unit 132 extracts the respective regional images to correctthe distortion. The HDR image composition unit 133 then combines thefront image 20F, the rear image 20B, the right-side image 20R, and theleft-side image 20L in which the distortion in the long-period exposureimage and the short-period exposure image is corrected.

The controller 16 controls to store, in the memory card 170, the frontimage 20F, the rear image 20B, the right-side image 20R, and theleft-side image 20L after being combined by the HDR image compositionunit 133. The controller 16 may control to store the 360-degree capturedimages of the long-period exposure image and the short-period exposureimage generated by the imaging unit 12 as illustrated in FIG. 4 in thememory card 170. The controller 16 desirably controls to store the frontimage 20F, the rear image 20B, the right-side image 20R and theleft-side image 20L, and also the 360-degree captured images in thememory card 170.

The controller 16 may control the monitor 18 to display a four-dividedimage in which the front image 20F, the rear image 20B, the right-sideimage 20R, and the left-side image 20L are arranged in a frame. Thecontroller 16 may control the monitor 18 to display a two-divided imagein which the rear image 20B and the right-side image 20R are arranged ina frame. The controller 16 may control the monitor 18 to display onlyone image (such as the front image 20F) chosen from the front image 20F,the rear image 20B, the right-side image 20R, the left-side image 20L.

The communication unit 15 may externally send the image being capturedby the vehicle imaging device 100 or the image recorded in the recordreproduction unit 17. The communication unit 15 may be omitted.

The processing executed by the image processing unit 13, the imageanalyzer 14, or the controller 16 is described below with reference tothe flowcharts shown in FIG. 8 and FIG. 9. When the processing shown inFIG. 8 is started, the front-rear-right-left determination unit 142provisionally determines the front, rear, right, and left directions inaccordance with the captured image (the combined image output from theHDR image composition unit 133) in step S1.

The image analyzer 14 determines whether the vehicle 200 has moved instep S2. The image analyzer 14 can determine that the vehicle 200 hasmoved when the motion vector detector 141 detects the motion vectors.The controller 16 may determine whether the vehicle 200 has moved inaccordance with the information acquired from a controller area network(CAN) of the vehicle 200.

When the vehicle 200 has not moved yet (NO), the image analyzer 14 (orthe controller 16) repeats the processing in step S2. When the vehicle200 has moved (YES), the image rotation unit 131 rotates the 360-degreecaptured image about the vanishing point Pv1 of the diverging motionvectors to adjust the direction of the front image 20F in step S3, andtemporarily finishes the processing.

When the processing shown in FIG. 9 is started, the motion vectordetector 141 detects the vanishing point Pv1 of the diverging motionvectors and the vanishing point Pv2 of the converging motion vectors instep S11. The measurement unit 161 measures the generation time of thevanishing point Pv1 and the generation time of the vanishing point Pv2present in the front image 20F in step S12.

The controller 16 determines whether a predetermined period of time haselapsed in step S13. The predetermined period of time is 10 minutes, forexample. When the predetermined period of time has not elapsed yet (NO),the controller 16 repeats the processing in step S13. When thepredetermined period of time has elapsed (YES), the controller 16determines whether the generation time of the vanishing point Pv1 islonger than the generation time of the vanishing point Pv2 in step S14.The term “generation time” refers to a total time within thepredetermined period of time.

When the generation time of the vanishing point Pv1 is longer than thegeneration time of the vanishing point Pv2 in step S14 (YES), the frontimage 20F in which the direction is adjusted in step S3 shown in FIG. 8is determined to conform to the actual forward direction of the vehicle200. The controller 16, the image processing unit 13, and the imageanalyzer 14 then finish the processing.

The HDR image composition unit 133 in this case combines the front image20F, the rear image 20B, the right-side image 20R, and the left-sideimage 20L in each of the long-period exposure image and the short-periodexposure image in which the direction is adjusted in step S3, andoutputs the combined image.

When the generation time of the vanishing point Pv1 is not longer thanthe generation time of the vanishing point Pv2 in step S14 (NO), thefront image 20F in which the direction is adjusted in step S3 shown inFIG. 8 is determined to be the rear side, instead of the actual frontside of the vehicle 200. The reason for this is that the vehicle 200moves backward in step S2 and the direction of the front image 20F isadjusted about the vanishing point Pv1 temporarily generated in theimage on the rear side of the vehicle 200.

The front-rear-right-left determination unit 142 then inverts thefront-rear direction in step S15 when the generation time of thevanishing point Pv1 is not longer than the generation time of thevanishing point Pv2 in step S14. In particular, thefront-rear-right-left determination unit 142 reverses the front imageregion and the rear image region, and reverses the right-side imageregion and the left-side image region. The image rotation unit 131rotates the 360-degree captured image about the vanishing point Pv1 toadjust the direction of the front image 20F in step S16, and finishesthe processing.

The HDR image composition unit 133 in this case combines the front image20F, the rear image 20B, the right-side image 20R, and the left-sideimage 20L in each of the long-period exposure image and the short-periodexposure image in which the front-rear direction is inverted in step 315and the direction is adjusted in step S16, and outputs the combinedimage.

The processing in step S16 is not necessarily, but preferably executed.

FIG. 10A to FIG. 10D schematically show examples of the front image 20F,the rear image 20B, the right-side image 20R, and the left-side image20L in the state in which the direction of the front image 20F has beenadjusted to conform to the actual forward direction of the vehicle 200through the processing as described above. As illustrated in FIG. 10,the displacement of the front image 20F toward the A-pillar 203AL on theleft side has been canceled out. As illustrated in FIG. 10B, thedisplacement of the rear image 20B toward the right side of the vehicle200 has been canceled out. As illustrated in FIG. 10C, the displacementof the right-side image 20R toward the front side has been canceled out.As illustrated in FIG. 10D, the displacement of the left-side image 20Ltoward the rear side has been canceled out.

In a first embodiment, only the front image 20F and the rear image 20Bmay be generated while the generation of the right-side image 20R andthe left-side image 20L is omitted.

As described above, the vehicle imaging device 100 according to a firstembodiment includes the image rotation unit 131, the image extractionunit 132, the front-rear-right-left determination unit 142, the motionvector detector 141, and the measurement unit 161. The motion vectordetector 141 detects the motion vectors of the captured image of thesubject imaged through 360 degrees by the imaging device 12. Thefront-rear-right-left determination unit 142 determines the front, rear,right, and left directions of the vehicle 200 based on the capturedimage, and determines the positions of at least the front image regionand the rear image region in the captured image in the circumferentialdirection.

The image rotation unit 131 rotates the captured image about thevanishing point Pv1 (a first vanishing point) of the plural motionvectors radially diverging among the motion vectors detected by themotion vector detector 141 immediately after the vehicle 200 startsmoving. The image rotation unit 131 then adjusts the positions of thefront image region and the rear image region in the circumferentialdirection.

The measurement unit 161 measures a first generation time of thevanishing point Pv1 generated in the front image region within thepredetermined period of time in the state in which the image rotationunit 131 adjusts the positions of the front image region and the rearimage region in the circumferential direction. The measurement unit 161also measures a second generation time of the vanishing point Pv2 (asecond vanishing point) of the plural converging motion vectorsgenerated in the front image region within the predetermined period oftime.

The image rotation unit 131 keeps the positions of the front imageregion and the rear image region in the circumferential direction whenthe first generation time measured by the measurement unit 161 is longerthan the second generation time. The image rotation unit 131 rotates thecaptured image so as to reverse the front image region and the rearimage region when the first generation time measured by the measurementunit 161 is not longer than the second generation time.

The image extraction unit 132 extracts the respective regional images ofthe front image region and the rear image region kept or reversed by theimage rotation unit 131 in the captured image to generate the frontimage 20F and the rear image 20B.

As described above, the vehicle imaging device 100 according to a firstembodiment can correctly extract the front image region and the rearimage region of the vehicle 200 from the 360-degree captured image so asto generate the front image 20F and the rear image 20B.

The image rotation unit 131 desirably rotates the captured image aboutthe vanishing point Pv1 generated in the regional image newly defined asthe front image region after rotating the captured image to reverse thefront image region and the rear image region, and adjusts the positionsof the front image region and the rear image region in thecircumferential direction.

The image extraction unit 132 desirably corrects the distortion of thefront image region and the rear image region extracted and generates thefront image 20F and the rear image 20B so as to approximate the view onthe front and rear sides of the vehicle 200 that the person is presumedto actually see.

The front-rear-right-left determination unit 142 desirably determinesthe positions of the right-side image region and the left-side imageregion in the circumferential direction in the captured image, inaddition to the front image region and the rear image region. The imagerotation unit 131 desirably adjusts the positions of the right-sideimage region and the left-side image region in the circumferentialdirection, in addition to the front image region and the rear imageregion. The image extraction unit 132 desirably extracts the respectiveregional images of the right-side image region and the left-side imageregion in the captured image so as to generate the right-side image 20Rand the left-side image 20L, in addition to the front image region andthe rear image region.

Second Embodiment

A second embodiment provides a vehicle imaging device 100 that examinesa way of correcting a blur of an image of a subject imaged by thevehicle imaging device 100 so as to make a correction accurately. Theexplanations of the elements in a second embodiment common to those in afirst embodiment are not repeated below. The specific configurations ofthe vehicle imaging device 100 according to a second embodiment are thesame as those illustrated in FIG. 2.

FIG. 11 schematically illustrates a condition in which a subject such asa sign is present ahead of the vehicle 200, the vehicle 200 is comingcloser to and passing through the subject in association with themovement of the vehicle 200, and the subject is then relatively shiftedin the rearward direction. The subject such as a sign does not appearsimultaneously in the front image 20F, the right-side image 20R, or therear image 20B, but FIG. 11 illustrates the respective positions of thesubject relatively shifting in the front image 20F, the right-side image20R, and the rear image 20B.

The position of the subject is barely displaced between the long-periodexposure image 21L and the short-period exposure image 21S, and theimage of the subject is thus barely blurred in the front image 20F orthe rear image 20B since a temporal change of the subject is small. Incontrast, since the temporal change of the captured image of the subjectlocated closer to the vehicle 200 is larger in the right-side image 20Rand the left-side image 20L, the position of the subject is displacedbetween the long-period exposure image 21L and the short-period exposureimage 21S and the image of the subject is thus blurred in associationwith a difference in the imaging timing.

As described above, the image of the subject in the right-side image 20Rand the left-side image 20L tends to be blurred as compared with theimage of the subject in the front image 20F and the rear image 20B. Thesecond embodiment corrects a blur of the image of the subject only inthe right-side image 20R and the left-side image 20L as follows.

FIG. 11 illustrates the case in which the HDR image composition unit 133first shifts the position of the long-period exposure image 21L havingbeen acquired earlier in accordance with the motion vectors in theright-side image 20R so as to conform to the position of theshort-period exposure image 21S, and then combines the long-periodexposure image 21L and the short-period exposure image 21S together.While FIG. 11 illustrates the case in which the long-period exposure isprior to the short-period exposure, the order of the exposure can bereversed.

FIG. 12 illustrates a case of obtaining an image 21 of the subject withthe blur corrected in the right-side image 20R through the processing ofcorrecting the blur of the image by the HDR image composition unit 133.The image 21 with no blur can be obtained in the front image 20F and therear image 20B without the execution of the processing of correcting theblur of the image by the HDR image composition unit 133, since thetemporal change of the subject is small.

The processing executed by the image processing unit 13 or thecontroller 16 in a second embodiment is described below with referenceto the flowchart shown in FIG. 13. When the processing starts, the imageextraction unit 132 extracts the right-side image region and theleft-side image region in step S21. The processing in step S21 may bethe processing of extracting the front image region, the rear imageregion, the right-side image region, and the left-side image region, asin the case of a first embodiment.

The HDR image composition unit 133 refers to the motion vectors tocombine the long-period exposure image and the short-period exposureimage in the right-side image region and the left-side image region instep S22. This step corrects a blur of the image derived from thedifference in the imaging timing between the particular subject includedin the right-side image or the left-side image based on the long-periodexposure image 21L and the corresponding subject included in theright-side image or the left-side image based on the short-periodexposure image 21S.

The controller 16 then determines whether the power of the vehicleimaging device 100 is turned off in step S23. When the power of thevehicle imaging device 100 is not turned off yet (NO), the controller 16and the image processing unit 13 repeat the processing from step S21 tostep S23. When the power of the vehicle imaging device 100 has beenturned off (YES), the controller 16 finishes the process.

The configurations and the operations of the vehicle imaging device 100according to a second embodiment are as follows. The imaging unit 12 inthe vehicle imaging device 100 according to a second embodimentgenerates a long-period exposure image obtained such that a subject isimaged for a first exposure time, and a short-period exposure imageobtained such that the subject is imaged for a second exposure time. Thevehicle imaging device 100 according to a second embodiment includes theimage extraction unit 132, the HDR image composition unit 133, themotion vector detector 141, and the front-rear-right-left determinationunit 142.

The motion vector detector 141 detects the motion vectors of thecaptured image. The front-rear-right-left determination unit 142determines the positions of at least the right-side image region and theleft-side image region in the circumferential direction in the capturedimage. The image extraction unit 132 extracts the respective regionalimages of the right-side image region and the left-side image region ofthe captured image so as to generate the right-side image 20R and theleft-side image 20L.

The HDR image composition unit 133 combines the right-side image 20R andthe left-side image 20L based on the long-period exposure image with theright-side image 20R and the left-side image 20L based on theshort-period exposure image generated by the image extraction unit 132.The HDR image composition unit 133 when combining the respective imagesrefers to the motion vectors detected in the right-side image region orthe left-side image region by the motion vector detector 141. Thisprocessing expands the dynamic range of the right-side image 20R or theleft-side image 20L, and corrects the blur of the subject included inthe right-side image 20R or the left-side image 20L

The vehicle imaging device 100 according to a second embodiment thus cancorrect the blur of the image accurately.

The front-rear-right-left determination unit 142 desirably furtherdetermines the positions of the front image region and the rear imageregion in the circumferential direction in the captured image, inaddition to the right-side image region and the left-side image region.The image extraction unit 132 desirably extracts the respective regionalimages of the front image region and the rear image region of thecaptured image, in addition to the right-side image region and theleft-side image region, so as to further generate the front image 20Fand the rear image 20B.

The HDR image composition unit 133 desirably combines the front image20F and the rear image 20B based on the long-period exposure image withthe front image 20F and the rear image 20B based on the short-periodexposure image generated by the image extraction unit 132, withoutreferring to the motion vectors detected by the motion vector detector141. This expands the dynamic range of the front image 20F and the rearimage 20B. The image rotation unit 131 is not necessarily, butpreferably included in a second embodiment.

Third Embodiment

A third embodiment is an embodiment developed from a second embodiment.The third embodiment provides a vehicle imaging device 100 that examineswhich subject having a blur of an image to be corrected should be chosenfrom subjects included in images generated by the vehicle imaging device100, so as to correct the blur of the image of the chosen subjectaccurately. The explanations of the elements in a third embodimentcommon to those in a first embodiment are not repeated below. Thespecific configurations of the vehicle imaging device 100 according to athird embodiment are the same as those illustrated in FIG. 2.

FIG. 14A and FIG. 14B are views showing examples of the right-side image20R and the left-side image 20L. As illustrated in FIG. 14A, theright-side image 20R includes, as subjects, a vehicle 230 traveling inthe adjacent lane on the right side of the vehicle 200 that is the hostvehicle (not illustrated) and a sign 31. The vehicle 230 is travelingfaster than the vehicle 200, and relatively shifts in the leftwarddirection (toward the front side of the vehicle 200) in the right-sideimage 20R. The sign 31 relatively shifts in the rightward direction(toward the rear side of the vehicle 200) in the right-side image 20R.The left-side image 20L includes a sign 32 as a subject. The sign 32relatively shifts in the leftward direction (toward the rear side of thevehicle 200) in the left-side image 20L.

The controller 16 is assigned the following options as correction modeschosen upon correcting a blur of an image by the HDR image compositionunit 133 according to priority determined when plural motion vectors indifferent shifting directions are detected. The plural motion vectors indifferent shifting directions may be motion vectors in two directionsopposite to each other. The user of the vehicle imaging device 100 suchas the driver 300 chooses one of the correction modes via anunillustrated operating unit so as to set the chosen correction mode tothe controller 16.

Correction mode 1 is a mode of correcting a blur of a subject shiftingin the rearward direction of the vehicle 200. Correction mode 2 is amode of correcting a blur of a subject shifting in the forward directionof the vehicle 200. Correction mode 3 is a mode of correcting a blur ofa subject closer to the vehicle 200. Correction mode 4 is a mode ofcorrecting a blur of a subject shifting in the forward direction of thevehicle 200 when the area of the subject shifting in the forwarddirection is a predetermined proportion or greater in the right-sideimage 20R or the left-side image 20L. The predetermined proportion is20%, for example.

Regarding correction mode 3, the subject, when being a stationaryobject, shifts at a lower speed as the subject is distant from thevehicle 200, and shifts at a higher speed as the subject is closer tothe vehicle 200. The controller 16 can specify the subject closer to thevehicle 200 in accordance with the motion vectors. The image analyzer 14may analyze the image so as to extract the subject closer to the vehicle200. The controller 16 in this case can controls the HDR imagecomposition unit 133 so as to correct the blur of the subject closer tothe vehicle 200 in accordance with the image analysis result obtained bythe image analyzer 14.

The controller 16 desirably independently sets one of the fourcorrection modes 1 to 4 in each of the right-side image 20R and theleft-side image 20L.

In the situation illustrated in FIG. 14A, when correction mode 1 ischosen, the blur of the image of the sign 31 is corrected by the HDRimage composition unit 133 in the same manner as described withreference to FIG. 11 and FIG. 12. When correction mode 2 is chosen, theblur of the image of the vehicle 230 is corrected by the HDR imagecomposition unit 133. When correction mode 3 is chosen, the blur of theimage of the vehicle 230, which is closer to the vehicle 200 than thesign 31, is corrected by the HDR image composition unit 133.

In the situation illustrated in FIG. 14A, when correction mode 4 ischosen, the blur of the image of the vehicle 230 is corrected by the HDRimage composition unit 133, since the area of the image of the vehicle230 relatively shifting in the forward direction of the vehicle 200 is20% or greater in the right-side image 20R.

In the situation illustrated in FIG. 14B, only the motion vector of thesign 32 shifting in the leftward direction is present. The controller 16thus controls the HDR image composition unit 133 to correct the blur ofthe image of the sign 32 while referring to the motion vector in whichthe sign 32 shifts regardless of the setting of the correction mode.

The processing executed by the image processing unit 13 or thecontroller 16 in a third embodiment is described below with reference tothe flowchart shown in FIG. 15. FIG. 15 illustrates a case ofdetermining that there are motion vectors in two directions opposite toeach other after starting the processing.

In step S31 in FIG. 15, the image extraction unit 132 extracts theright-side image region and the left-side image region. The processingin step S31 may be the processing of extracting the front image region,the rear image region, the right-side image region, and the left-sideimage region, as in the case of a first embodiment. The controller 16determines whether to choose correction mode 1 of correcting the blur ofthe subject shifting in the rearward direction of the vehicle 200 priorto the other subject. When correction mode 1 is chosen (YES), the HDRimage composition unit 133 corrects the blur of the image of the subjectshifting in the rearward direction while referring to the rearwardmotion vector in step S33, and leads the process to proceed to step S39.

When correction mode 1 is not chosen in step S32 (NO), the controller 16determines whether to choose correction mode 2 of correcting the blur ofthe subject shifting in the forward direction of the vehicle 200 priorto the other subject in step S34. When correction mode 2 is chosen(YES), the HDR image composition unit 133 corrects the blur of the imageof the subject shifting in the forward direction while referring to theforward motion vector in step S35, and leads the process to proceed tostep S39.

When correction mode 2 is not chosen in step S34 (NO), the controller 16determines whether to choose correction mode 3 of correcting the blur ofthe subject closer to the vehicle 200 prior to the other subject in stepS36. When correction mode 3 is chosen (YES), the HDR image compositionunit 133 corrects the blur of the image of the subject closer to thevehicle 200 while referring to the motion vector of the correspondingsubject in step S37, and leads the process to proceed to step S39.

When correction mode 3 is not chosen in step S36 (NO), correction mode 4is determined to be chosen. The controller 16 determines whether thearea of the subject shifting in the forward direction of the vehicle 200is the predetermined proportion or greater in step S38. When the area ofthe subject shifting in the forward direction of the vehicle 200 is notthe predetermined proportion or greater (NO), the HDR image compositionunit 133 corrects the blur of the image of the subject shifting in therearward direction while referring to the rearward motion vector in stepS33, and leads the process to proceed to step S39.

When the area of the subject shifting in the forward direction of thevehicle 200 is the predetermined proportion or greater (YES) in stepS38, the HDR image composition unit 133 corrects the blur of the imageof the subject shifting in the forward direction while referring to theforward motion vector in step S35, and leads the process to proceed tostep S39.

The controller 16 then determines whether the power of the vehicleimaging device 100 is turned off in step S39. When the power of thevehicle imaging device 100 is not turned off yet (NO), the controller 16and the image processing unit 13 repeat the processing from step S31 tostep S39. When the power of the vehicle imaging device 100 has beenturned off (YES), the controller 16 finishes the process.

The configurations and the operations of the vehicle imaging device 100according to a third embodiment are as follows. The imaging unit 12 inthe vehicle imaging device 100 according to a third embodiment generatesa long-period exposure image obtained such that a subject is imaged fora first exposure time, and a short-period exposure image obtained suchthat the subject is imaged for a second exposure time. The vehicleimaging device 100 according to a third embodiment includes the imageextraction unit 132, the HDR image composition unit 133, the motionvector detector 141, and the front-rear-right-left determination unit142.

The motion vector detector 141 detects the motion vectors of thecaptured image. The front-rear-right-left determination unit 142determines the positions of at least the right-side image region and theleft-side image region in the circumferential direction in the capturedimage. The image extraction unit 132 extracts the respective regionalimages of the right-side image region and the left-side image region ofthe captured image so as to generate the right-side image 20R and theleft-side image 20L.

The HDR image composition unit 133 combines the right-side image 20R andthe left-side image 20L based on the long-period exposure image with theright-side image 20R and the left-side image 20L based on theshort-period exposure image generated by the image extraction unit 132.The HDR image composition unit 133 when combining the respective imagesrefers to the motion vectors detected in the right-side image region orthe left-side image region by the motion vector detector 141.

The motion vector detector 141 sometimes detects plural motion vectorsin different directions in the right-side image region or the left-sideimage region. The HDR image composition unit 133 refers to the motionvector of the subject to be corrected so as to correct the blur of theimage of the subject included in the right-side image 20R or theleft-side image 20L and determined as a correction target in accordancewith the preliminarily chosen correction mode.

The vehicle imaging device 100 according to a third embodiment thus cancorrect the blur of the image of the chosen subject accurately.

The plural motion vectors in different directions can be a first motionvector in the rearward direction of the vehicle 200 and a second motionvector in the forward direction of the vehicle 200. One of thecorrection modes can be chosen for the subject as a correction targetrelatively shifting in the rearward direction of the vehicle 200. TheHDR image composition unit 133 in this mode refers to the first motionvector to combine the right-side image 20R or the left-side image 20Lgenerated in accordance with the long-period exposure image with theright-side image 20R or the left-side image 20L generated in accordancewith the short-period exposure image.

Another correction mode can be chosen for the subject as a correctiontarget relatively shifting in the forward direction of the vehicle 200.The HDR image composition unit 133 in this mode refers to the secondmotion vector to combine the right-side image 20R or the left-side image20L generated in accordance with the long-period exposure image with theright-side image 20R or the left-side image 20L generated in accordancewith the short-period exposure image.

When a plurality of subjects are present in the right-side image 20R orthe left-side image 20L, another correction mode, other than the abovetwo modes, may be chosen for the subject as a correction target closerto the vehicle 200. The HDR image composition unit 133 refers to thefirst or second motion vector in which the subject closer to the vehicle200 is shifting, and combines the right-side image 20R or the left-sideimage 20L based on the long-period exposure image with the right-sideimage 20R or the left-side image 20L based on the short-period exposureimage.

The right-side image 20R or the left-side image 20L sometimes includes afirst subject relatively shifting in the rearward direction of thevehicle 200 and a second subject relatively shifting in the forwarddirection of the vehicle 200. Still another correction mode, other thanthe above two or three correction modes, then may be chosen for thesubject as a correction target according to the proportion of the areaof the second subject in the right-side image 20R or the left-side image20L.

The HDR image composition unit 133 refers to the first motion vector tocombine the right-side image 20R or the left-side image 20L based on thelong-period exposure image with the right-side image 20R or theleft-side image 20L based on the short-period exposure image when thearea of the second subject is not a predetermined proportion or greaterin the right-side image 20R or the left-side image 20L. The HDR imagecomposition unit 133 refers to the second motion vector to combine theright-side image 20R or the left-side image 20L based on the long-periodexposure image with the right-side image 20R or the left-side image 20Lbased on the short-period exposure image when the area of the secondsubject is the predetermined proportion or greater in the right-sideimage 20R or the left-side image 20L.

Fourth Embodiment

A fourth embodiment provides a vehicle imaging device 100 that canacquire the front image 20F, the rear image 20B, the right-side image20R, and the left-side image 20L accurately in accordance with anincident direction of sunlight. The explanations of the elements in afourth embodiment common to those in a first embodiment are not repeatedbelow. The specific configurations of the vehicle imaging device 100according to a fourth embodiment are the same as those illustrated inFIG. 2.

FIG. 16 illustrates a case in which a vehicle 241 is traveling ahead ofthe vehicle 200 that is the host vehicle, and a vehicle 242 is travelingbehind the vehicle 200, both being traveling in the same lane as thevehicle 200. FIG. 16 also illustrates a case in which a vehicle 243 istraveling in the right lane and a vehicle 244 is traveling in the leftlane next to the vehicle 200. In a case in which the vehicle 200 and theother vehicles 241 to 244 are irradiated with the sunlight in thedirection indicated by the solid-white arrow, the vehicle 200 and theother vehicles 241 to 244 each include a bright part without hatchingand a dark part indicated by hatching. The bright part and the dark partare caused by the irradiation of the sunlight in the respective subjectsdepending on the incident direction of the sunlight.

The vehicle imaging device 100 according to a fourth embodiment changesthe way of combining the long-period exposure image and the short-periodexposure image by the HDR image composition unit 133 depending on theincident direction of the sunlight.

As illustrated in FIG. 17, the controller 16 divides the 360-degreedirection imaged by the vehicle imaging device 100 into eight 45-degreedirections, for example. The controller 16 controls the HDR imagecomposition unit 133 to change the way of combining the long-periodexposure image and the short-period exposure image depending on thedetermination of which is the incident direction of the sunlight amongthe eight directions. The eight directions are referred to below as afront direction, a front-right direction, a right direction, arear-right direction, a rear direction, a rear-left direction, a leftdirection, and a front-left direction. The image analyzer 14 candetermine the incident direction of the sunlight by analyzing thecaptured image. The image analyzer 141 functions as a sunlightincident-direction determination unit of determining the incidentdirection of the sunlight.

The processing executed by the image processing unit 13, the imageanalyzer 14, or the controller 16 in a fourth embodiment is describedbelow with reference to the flowcharts shown in FIG. 18A and FIG. 18B.When the processing in FIG. 18A starts, the image analyzer 14 determinesthe incident direction of the sunlight in step S401. The controller 16determines whether the incident direction of the sunlight determined bythe image analyzer 14 is the front direction in step S402.

When the incident direction of the sunlight is determined to be thefront direction in step S402 (YES), the controller 16 controls the HDRimage composition unit 133 to set the ratio of the long-period exposureimage in the front image 20F to be greater than the ratio of thelong-period exposure image in each of the rear image 20B, the right-sideimage 20R, and the left-side image 20L in step S403. The reason for thisis that the vehicle imaging device 100 images the rear side of thevehicle 241, which is shaded, traveling ahead of the vehicle 200. Thecontroller 16 then leads the process to proceed to step S418 continuedfrom step S403.

In a case in which the ratio of the long-period exposure image to theshort-period exposure image in each of the rear image 20B, theright-side image 20R, and the left-side image 20L is 4:6, for example,the controller 16 controls the HDR image composition unit 133 to set theratio of the long-period exposure image to the short-period exposureimage in the front image 20F to 9:1.

When the incident direction of the sunlight is determined not to be thefront direction in step S402 (NO), the controller 16 determines whetherthe incident direction of the sunlight is determined to be thefront-right direction in step S404. When the incident direction of thesunlight is determined to be the front-right direction (YES), thecontroller 16 controls the HDR image composition unit 133 to set theratio of the long-period exposure image in each of the front image 20Fand the right-side image 20R to be greater than the ratio of thelong-period exposure image in each of the rear image 20B and theleft-side image 20L in step S405. The controller 16 then leads theprocess to proceed to step S418 continued from step S405.

In a case in which the ratio of the long-period exposure image to theshort-period exposure image in the rear image 20B and the left-sideimage 20L is 4:6, for example, the controller 16 controls the HDR imagecomposition unit 133 to set the ratio of the long-period exposure imageto the short-period exposure image in the front image 20F and theright-side image 20R to 9:1.

When the incident direction of the sunlight is determined not to be thefront-right direction in step S404 (NO), the controller 16 determineswhether the incident direction of the sunlight is determined to be theright direction in step S406. When the incident direction of thesunlight is determined to be the right direction (YES), the controller16 controls the HDR image composition unit 133 to set the ratio of thelong-period exposure image in the right-side image 20R to be greaterthan the ratio of the long-period exposure image in each of the frontimage 20F, the rear image 20B, and the left-side image 20L in step S407.The way of increasing the ratio of the long-period exposure image is thesame as the way described in step S405. The controller 16 then leads theprocess to proceed to step S418 continued from step S407.

When the incident direction of the sunlight is determined not to be theright direction in step S406 (NO), the controller 16 determines whetherthe incident direction of the sunlight is determined to be therear-right direction in step S408. When the incident direction of thesunlight is determined to be the rear-right direction (YES), thecontroller 16 controls the HDR image composition unit 133 to set theratio of the long-period exposure image in each of the rear image 20Band right-side image 20R to be greater than the ratio of the long-periodexposure image in each of the front image 20F and the left-side image20L in step S409. The way of increasing the ratio of the long-periodexposure image is the same as the way described in step S405. Thecontroller 16 then leads the process to proceed to step S418 continuedfrom step S409.

When the incident direction of the sunlight is determined not to be therear-right direction in step S408 (NO), the controller 16 determineswhether the incident direction of the sunlight is determined to be therear direction in step S410 shown in FIG. 18B. When the incidentdirection of the sunlight is determined to be the rear direction (YES),the controller 16 controls the HDR image composition unit 133 to set theratio of the long-period exposure image in the rear image 20B to begreater than the ratio of the long-period exposure image in each of thefront image 20F, the right-side image 20R, and the left-side image 20Lin step S411. The way of increasing the ratio of the long-periodexposure image is the same as the way described in step S405. Thecontroller 16 then leads the process to proceed to step S418 continuedfrom step S411.

When the incident direction of the sunlight is determined not to be therear direction in step S410 (NO), the controller 16 determines whetherthe incident direction of the sunlight is determined to be the rear-leftdirection in step S412. When the incident direction of the sunlight isdetermined to be the rear-left direction (YES), the controller 16controls the HDR image composition unit 133 to set the ratio of thelong-period exposure image in each of the rear image 20B and left-sideimage 20L to be greater than the ratio of the long-period exposure imagein each of the front image 20F and the right-side image 20L in step3413. The way of increasing the ratio of the long-period exposure imageis the same as the way described in step S405.

The controller 16 then leads the process to proceed to step S418continued from step S413.

When the incident direction of the sunlight is determined not to be therear-left direction in step S412 (NO), the controller 16 determineswhether the incident direction of the sunlight is determined to be theleft direction in step S414. When the incident direction of the sunlightis determined to be the left direction (YES), the controller 16 controlsthe HDR image composition unit 133 to set the ratio of the long-periodexposure image in the left-side image 20L to be greater than the ratioof the long-period exposure image in each of the front image 20F, therear image 20B, and the right-side image 20R in step S415. The way ofincreasing the ratio of the long-period exposure image is the same asthe way described in step S405. The controller 16 then leads the processto proceed to step S418 continued from step S415.

When the incident direction of the sunlight is determined not to be theleft direction in step S414 (NO), the controller 16 determines whetherthe incident direction of the sunlight is determined to be thefront-left direction in step S416. When the incident direction of thesunlight is determined to be the front-left direction (YES), thecontroller 16 controls the HDR image composition unit 133 to set theratio of the long-period exposure image in each of the front image 20Fand left-side image 20L to be greater than the ratio of the long-periodexposure image in each of the rear image 20B and the right-side image20L in step S417. The way of increasing the ratio of the long-periodexposure image is the same as the way described in step S405. Thecontroller 16 then leads the process to proceed to step S418 continuedfrom step S417.

When the incident direction of the sunlight is determined not to be thefront-left direction in step S416 (NO), the controller 16 leads theprocess to proceed to step S418.

The controller 16 then determines whether the power of the vehicleimaging device 100 is turned off in step S418. When the power of thevehicle imaging device 100 is not turned off yet (NO), the imageprocessing unit 13, the image analyzer 14, or the controller 16 repeatsthe processing from step S401 to step S418. When the power of thevehicle imaging device 100 has been turned off (YES), the controller 16finishes the process.

The configurations and the operations of the vehicle imaging device 100according to a fourth embodiment are as follows. The imaging unit 12 inthe vehicle imaging device 100 according to a fourth embodimentgenerates a long-period exposure image obtained such that a subject isimaged for a first exposure time, and a short-period exposure imageobtained such that the subject is imaged for a second exposure time. Thevehicle imaging device 100 according to a fourth embodiment includes thesunlight incident-direction determination unit (the image analyzer 14),the image extraction unit 132, the HDR image composition unit 133, andthe front-rear-right-left determination unit 142.

The front-rear-right-left determination unit 142 determines thepositions of the front image region, the rear image region, theright-side image region, and the left-side image region in thecircumferential direction in the captured image. The image extractionunit 132 extracts the respective regional images of the front imageregion, the rear image region, the right-side image region, and theleft-side image region of the captured image, and generates therespective directional images of the front image 20F, the rear image20B, the right-side image 20R, and the left-side image 20L.

The HDR image composition unit 133 combines the front image 20F, therear image 20B, the right-side image 20R, and the left-side image 20Lgenerated in accordance with the long-period exposure image with thefront image 20F, the rear image 20B, the right-side image 20R, and theleft-side image 20L generated in accordance with the short-periodexposure image.

The HDR image composition unit 133 sets the ratio of the directionalimage based on the long-period exposure image chosen from the frontimage 20F, the rear image 20B, the right-side image 20R, and theleft-side image 20L depending on the incident direction of the sunlightdetermined by the sunlight incident-direction determination unit to begreater than the ratio of the other directional images based on thelong-period exposure image not chosen.

The vehicle imaging device 100 according to a fourth embodiment canacquire the front image 20F, the rear image 20B, the right-side image20R, and the left-side image 20L accurately in accordance with theincident direction of the sunlight.

The sunlight incident-direction determination unit divides the360-degree direction imaged by the vehicle imaging device 100 into aplurality of directions including at least the front direction, the reardirection, the right direction, and the left direction, so as todetermine which is the incident direction of the sunlight.

The HDR image composition unit 133 desirably increases the ratio of thefront image based on the long-period exposure image when the incidentdirection of the sunlight is the front direction, and increases theratio of the rear image based on the long-period exposure image when theincident direction of the sunlight is the rear direction. The HDR imagecomposition unit 133 desirably increases the ratio of the right-sideimage based on the long-period exposure image when the incidentdirection of the sunlight is the right direction, and increases theratio of the left-side image based on the long-period exposure imagewhen the incident direction of the sunlight is the left direction.

The sunlight incident-direction determination unit desirably divides the360-degree direction imaged by the vehicle imaging device 100 into aplurality of directions including the front-right direction, therear-right direction, the rear-left direction, and the front-leftdirection, in addition to the front direction, the rear direction, theright direction, and the left direction, so as to determine which is theincident direction of the sunlight.

The HDR image composition unit 133 desirably increases the ratio of thefront image and the right-side image based on the long-period exposureimage when the incident direction of the sunlight is the front-rightdirection, and increases the ratio of the rear image and the right-sideimage based on the long-period exposure image when the incidentdirection of the sunlight is the rear-right direction. The HDR imagecomposition unit 133 desirably increases the ratio of the rear image andthe left-side image based on the long-period exposure image when theincident direction of the sunlight is the rear-left direction, andincreases the ratio of the front image and the left-side image based onthe long-period exposure image when the incident direction of thesunlight is the front-left direction.

Fifth Embodiment

A fifth embodiment provides a vehicle imaging device 100 that canacquire the front image 20F, the rear image 20B, the right-side image20R, and the left-side image 20L accurately in accordance with therespective positions of the traveling vehicle 200 before entering atunnel, during traveling in the tunnel, and after coming out of thetunnel. The explanations of the elements in a fifth embodiment common tothose in a first embodiment are not repeated below. The specificconfigurations of the vehicle imaging device 100 according to a fifthembodiment are the same as those illustrated in FIG. 2.

As illustrated in FIG. 19, the vehicle 200 is traveling in a region R51on a road and is reaching a tunnel 50. The image inside the tunnel 50included in the front image 20F at this point has a predeterminedproportion or greater. To clearly visually recognize the image insidethe tunnel 50, the controller 16 desirably controls the HDR imagecomposition unit 133 so as to increase a ratio of the long-periodexposure image in the front image 20F when the HDR image compositionunit 133 combines the long-period exposure image with the short-periodexposure image.

In a case in which the ratio of the long-period exposure image to theshort-period exposure image is 4:6 before the vehicle 200 reaches theregion R51 in a state in which the image inside the tunnel 50 is notincluded in the captured image, for example, the controller 16 increasesand sets the ratio of the long-period exposure image to the short-periodexposure image in the front image 20F to 8:2.

The vehicle 200 is further coming closer to the entrance 50in of thetunnel 50, and the vehicle 200 reaches a region R52 to partly enter thetunnel 50. The controller 16 then desirably controls the HDR imagecomposition unit 133 so as to increase the ratio of the long-periodexposure image in each of the right-side image 20R and the left-sideimage 20L when combining the long-period exposure image with theshort-period exposure image.

In a case in which the ratio of the long-period exposure image to theshort-period exposure image in each of the right-side image 20R and theleft-side image 20L is 4:6 when the vehicle 200 is traveling in theregion 51, for example, the controller 16 increases and sets the ratioof the long-period exposure image to the short-period exposure image ineach of the right-side image 20R and the left-side image 20L to 8:2.

The vehicle 200 keeps traveling in the tunnel 50 and reaches a region53. The image excluding the tunnel 50 toward the entrance 50in of thetunnel 50 included in the rear image 50B at this point has apredetermined proportion or less. The controller 16 desirably controlsthe HDR image composition unit 133 so as to increase the ratio of thelong-period exposure image in the rear image 20B when combining thelong-period exposure image with the short-period exposure image.

In a case in which the ratio of the long-period exposure image to theshort-period exposure image in the rear image 20B is 4:6 when thevehicle 200 is traveling in the regions R51 and R52, for example, thecontroller 16 increases and sets the ratio of the long-period exposureimage to the short-period exposure image in the rear image 20B to 8:2.

The vehicle 200 keeps traveling in the tunnel 50 and reaches a regionR54 closer to the exit 50out of the tunnel 50. The image excluding thetunnel 50 toward the exit 50out of the tunnel 50 included in the frontimage 20F at this point has a predetermined proportion or greater. Toclearly visually recognize the image outside the tunnel 50, thecontroller 16 desirably controls the HDR image composition unit 133 soas to decrease the ratio of the long-period exposure image in the frontimage 20F when combining the long-period exposure image with theshort-period exposure image.

Since the ratio of the long-period exposure image to the short-periodexposure image in the front image 20F immediately before the vehicle 200reaches the region R54 is 8:2 in the above case, the ratio of thelong-period exposure image to the short-period exposure image is set to4:6 when reaching the region R54.

The vehicle 200 keeps traveling in the tunnel 50, and the vehicle 200reaches a region R55 to partly come out of the exit 50out of the tunnel50. The controller 16 then desirably controls the HDR image compositionunit 133 so as to decrease the ratio of the long-period exposure imagein each of the right-side image 20R and the left-side image 20L whencombining the long-period exposure image with the short-period exposureimage.

Since the ratio of the long-period exposure image to the short-periodexposure image in each of the right-side image 20R and the left-sideimage 20L immediately before the vehicle 200 reaches the region R55 is8:2 in the above case, the ratio of the long-period exposure image tothe short-period exposure image is set to 4:6 after reaching the regionR55.

When the vehicle 200 completely comes out of the tunnel 50 and reaches aregion R56, the image inside the tunnel 50 included in the rear image20B has a predetermined proportion or less. The controller 16 thendesirably controls the HDR image composition unit 133 so as to decreasethe ratio of the long-period exposure image in the rear image 20R whenthe HDR image composition unit 133 combines the long-period exposureimage with the short-period exposure image.

Since the ratio of the long-period exposure image to the short-periodexposure image in the rear image 20B immediately before the vehicle 200reaches the region R56 is 8:2 in the above case, the ratio of thelong-period exposure image to the short-period exposure image is set to4:6 after reaching the region R56.

The determination of which point the vehicle 200 is currently travelingin the regions R51 to R56 illustrated in FIG. 19 can be made by theimage analyzer 14 in accordance with the captured image. The imageanalyzer 14 functions as a tunnel travelling determination unit.

When the vehicle imaging device 100 includes a global navigationsatellite system (GNSS) receiver that receives radio waves from asatellite for a GNSS such as a global positioning system (GPS) and hasmap information, the controller 16 may detect the positions of thevehicle 200 at the respective points during traveling inside and outsidethe tunnel 50 in accordance with GNSS signals received by the GNSSreceiver and the map information. The controller 16 in this casefunctions as a tunnel travelling determination unit.

The processing executed by the image processing unit 13, the tunneltravelling determination unit (the image analyzer 14), or the controller16 in a fifth embodiment is described below with reference to theflowcharts shown in FIG. 20A and FIG. 20B. When the processing in FIG.20A starts, the tunnel travelling determination unit recognizes thetunnel 50 ahead of the vehicle 200 and determines whether the imageinside the tunnel 50 has a predetermined proportion or greater in stepS501.

When the image inside the tunnel 50 is determined to have thepredetermined proportion or greater in step S501 (YES), the controller16 controls the HDR image composition unit 133 to increase the ratio ofthe long-period exposure image in the front image 20F in step S502, andleads the process to proceed to step S513. When the image inside thetunnel 50 is determined not to be the predetermined proportion orgreater yet in step S501 (NO), the tunnel traveling determination unitdetermines whether the vehicle 200 is entering the tunnel 50 in stepS503.

When the vehicle 200 is determined to enter the tunnel 50 in step S503(YES), the controller 16 controls the HDR image composition unit 133 toincrease the ratio of the long-period exposure image in each of theright-side image 20R and the left-side image 20L in step S504, and leadsthe process to proceed to step S513. When the vehicle 200 is determinednot to enter the tunnel 50 yet in step S503 (NO), the tunnel travelingdetermination unit determines whether the image excluding the tunnel 50toward the entrance 50in of the tunnel 50 included in the rear image 20Bis a predetermined proportion or less in step S505.

When the image excluding the tunnel 50 toward the entrance 50in of thetunnel 50 is determined to be the predetermined proportion or less instep S505 (YES), the controller 16 controls the HDR image compositionunit 133 to increase the ratio of the long-period exposure image in therear image 20B in step S506, and leads the process to proceed to stepS513. When the image excluding the tunnel 50 toward the entrance 50in ofthe tunnel 50 is determined not to be the predetermined proportion orless in step S505 (NO), the tunnel traveling determination unitdetermines whether the image excluding the tunnel 50 toward the exit50out of the tunnel 50 included in the front image 20F is apredetermined proportion or greater in step S507 shown in FIG. 20B.

When the image excluding the tunnel 50 toward the exit 50out of thetunnel 50 is determined to be the predetermined proportion or greater instep S507 (YES), the controller 16 controls the HDR image compositionunit 133 to decrease the ratio of the long-period exposure image in thefront image 20F in step S508, and leads the process to proceed to stepS513. When the image excluding the tunnel 50 toward the exit 50out ofthe tunnel 50 is determined not to be the predetermined proportion orgreater in step S507 (NO), the tunnel traveling determination unitdetermines whether a part of the vehicle 200 comes out of the tunnel 50in step S509.

When a part of the vehicle 200 is determined to come out of the tunnel50 in step S509 (YES), the controller 16 controls the HDR imagecomposition unit 133 to decrease the ratio of the long-period exposureimage in each of the right-side image 20R and the left-side image 20L instep S510, and leads the process to proceed to step S513. When a part ofthe vehicle 200 is determined not to come out of the tunnel 50 in stepS509 (NO), the tunnel traveling determination unit determines whetherthe vehicle 200 comes out of the tunnel 50 and the image inside thetunnel 50 included in the rear image 20B is a predetermined proportionor less in step S511.

When the image inside the tunnel 50 is determined to be thepredetermined proportion or less in step S511 (YES), the controller 16controls the HDR image composition unit 133 to decrease the ratio of thelong-period exposure image in the rear image 20B in step S512, and leadsthe process to proceed to step S513. When the image inside the tunnel 50is determined not to be the predetermined proportion or less in stepS511 (NO), the controller 16 leads the process to proceed to step S513.

The controller 16 then determines whether the power of the vehicleimaging device 100 is turned off in step S513. When the power of thevehicle imaging device 100 is not turned off yet (NO), the imageprocessing unit 13, the tunnel traveling determination unit, or thecontroller 16 repeats the processing from step S501 to step S513. Whenthe power of the vehicle imaging device 100 has been turned off (YES),the controller 16 finishes the process.

The configurations and the operations of the vehicle imaging device 100according to a fifth embodiment are as follows. The imaging unit 12 inthe vehicle imaging device 100 according to a fifth embodiment generatesa long-period exposure image obtained such that a subject is imaged fora first exposure time, and a short-period exposure image obtained suchthat the subject is imaged for a second exposure time. The vehicleimaging device 100 according to a fifth embodiment includes the tunneltraveling determination unit (the image analyzer 14), the imageextraction unit 132, the HDR image composition unit 133, and thefront-rear-right-left determination unit 142.

The front-rear-right-left determination unit 142 determines thepositions of the front image region, the rear image region, theright-side image region, and the left-side image region in thecircumferential direction in the captured image. The image extractionunit 132 extracts the respective regional images of the front imageregion, the rear image region, the right-side image region, and theleft-side image region of the captured image, and generates therespective directional images of the front image 20F, the rear image20B, the right-side image 20R, and the left-side image 20L.

The HDR image composition unit 133 combines the front image 20F, therear image 20B, the right-side image 20R, and the left-side image 20Lgenerated in accordance with the long-period exposure image with thefront image 20F, the rear image 20B, the right-side image 20R, and theleft-side image 20L generated in accordance with the short-periodexposure image.

The tunnel traveling determination unit determines the states during theperiod in which the traveling vehicle 200 comes closer to the tunnel 50,enters the tunnel 50 and travels in the tunnel 50, and comes out of thetunnel 50.

The HDR image composition unit 133 adjusts the ratio of the directionalimage based on the long-period exposure image or the ratio of thedirectional image based on the short-period exposure image chosen fromthe front image 20F, the rear image 20B, the right-side image 20R, andthe left-side image 20L. The HDR image composition unit 133 adjusts therespective ratios based on the determination made by the tunneltraveling determination unit in accordance with the positions of thevehicle 200 at the respective points before entering the tunnel 50,during traveling in the tunnel 50, and after coming out of the tunnel50.

In particular, the HDR image composition unit 133 desirably adjusts therespective ratios in accordance with the positions of the vehicle 200 asfollows.

When the tunnel traveling determination unit determines that the vehicle200 comes close to the tunnel 50 and the image inside the tunnel 50 is apredetermined proportion or greater in the front image 20F, the HDRimage composition unit 133 desirably increases the ratio of the frontimage 20F based on the long-period exposure image.

When the tunnel traveling determination unit determines that the vehicle200 enters the tunnel 50, the HDR image composition unit 133 desirablyincreases the ratio of each of the right-side image 20R and theleft-side image 20L based on the long-period exposure image.

When the tunnel traveling determination unit determines that the imageexcluding the tunnel 50 toward the entrance 50in of the tunnel 50 afterthe vehicle 20 enters the tunnel 50 is a predetermined proportion orless in the rear image 20B, the HDR image composition unit 133 desirablyincreases the ratio of the rear image 20B based on the long-periodexposure image.

When the tunnel traveling determination unit determines that the vehicle200 comes closer to the exit 50out of the tunnel 50 and the imageexcluding the tunnel 50 toward the exit 50out of the tunnel 50 is apredetermined proportion or greater in the front image 20F, the HDRimage composition unit 133 desirably decreases the ratio of the frontimage 20F based on the long-period exposure image.

Namely, the HDR image composition unit 133 returns the ratio of thefront image 20F based on the long-period exposure image having beenincreased at the point when the vehicle 200 comes closer to the tunnel50 described above to the original ratio.

When the tunnel traveling determination unit determines that the vehicle200 comes out of the tunnel 50, the HDR image composition unit 133desirably decreases the ratio of each of the right-side image 20R andthe left-side image 20L based on the long-period exposure image. Namely,the HDR image composition unit 133 returns the ratio of the right-sideimage 20R and the left-side image 20L based on the long-period exposureimage having been increased at the point when the vehicle 200 enters thetunnel 50 described above to the original ratio.

When the tunnel traveling determination unit determines that the vehicle200 comes out of the tunnel 50 and the image inside the tunnel 50 is apredetermined proportion or less in the rear image 20B, the HDR imagecomposition unit 133 desirably decreases the ratio of the rear image 20Bbased on the long-period exposure image.

Namely, the HDR image composition unit 133 returns, to the originalratio, the ratio of the rear image 20B based on the long-period exposureimage having been increased at the point when the image excluding thetunnel 50 toward the entrance 50in of the tunnel 50 is the predeterminedproportion or less in the rear image 20B.

As described above, the vehicle imaging device 100 according to a fifthembodiment can acquire the front image 20F, the rear image 20B, theright-side image 20R, and the left-side image 20L accurately inaccordance with the respective positions of the traveling vehicle 200from the point before entering the tunnel 50 to the point after comingout of the tunnel 50.

Sixth Embodiment

A sixth embodiment provides a vehicle imaging device 100 that canacquire to save a captured image with a smaller blur upon an occurrenceof an event such as an accident to the vehicle 200. The explanations ofthe elements in a sixth embodiment common to those in a first embodimentare not repeated below.

As illustrated in FIG. 21, the vehicle imaging device 100 according to asixth embodiment includes an acceleration sensor 60 connected to the bus19. The acceleration sensor 60 is an example of an event detectionsensor that determines whether any event occurs to the vehicle 200. Therecord reproduction unit 17 includes the memory card 170 and a ringbuffer 171. The ring buffer 171 is an undetachable base memory includedin the vehicle imaging device 100. The memory card 170 is provided withan event recording region 172 and a normal recording region 173. Theevent recording region 172 is a recording region in which data is notoverwritten automatically.

The arrangement position of the event recording region 172 and thenormal recording region 173 is not limited to the memory card 170. Theevent recording region 172 may be provided in the base memory. Thenormal recording region 173 may be provided in the base memory. Theevent recording region 172 and the normal recording region 173 both maybe provided in the base memory.

The ring buffer 171 has a capacity sufficient to record captured imagedata of 360-degree captured images of long-period exposure images andshort-period exposure images for a predetermined period of time, and thecaptured image data is cyclically stored in the ring buffer 171. Inparticular, when the ring buffer 171 is filled to capacity with thecaptured image data stored, the oldest captured image data is rewrittento be replaced with the latest captured image data. The operation ofupdating the captured image data is repeated.

The front image 20F, the rear image 20B, the right-side image 20R, andthe left-side image 20L combined by the HDR image composition unit 133are recorded in the normal recording region 173 without being recordedtemporarily in the ring buffer 171.

The processing executed by the controller 16 according to a sixthembodiment is described below with reference to the flowchart shown inFIG. 22. When the processing starts, the controller 16 causes thecaptured image data for a predetermined period of time to be stored inthe ring buffer 171 in step S61. As described above, the captured imagedata is the data of the 360-degree captured images of the long-periodexposure images and the short-period exposure images.

The controller 16 determines whether any event occurs to the vehicle 200in accordance with a change in the acceleration detected by theacceleration sensor 60 in step S62. The controller 16 determines that anevent has occurred when the acceleration is rapidly increased or rapidlyreduced.

When no event is determined to have occurred in step S62 (NO), thecontroller 16 repeats the processing in step S61 and step S62. When anevent is determined to have occurred in step S62 (YES), the controller16 leads the process to proceed to step S63. The controller 16 copiesthe captured image data stored in the ring buffer 171 to the eventrecording region 172 in step S63, and finishes the processing.

A subject, which is preferably recorded in the normal recording region173 without blur, would be recorded undesirably in a blurred state uponthe occurrence of an event. In particular, the following case may bepresumed in which the image having a large blur is recorded in thenormal recording region 173.

In a case in which the area of the vehicle 230 illustrated in FIG. 14Ais less than 20% in the right-side image 20R, a blur in the image of thesign 31 relatively shifting in the rearward direction in the right-sideimage 20R is corrected by the HDR image composition unit 133. If anaccident between the vehicle 200 and the vehicle 230 occurs in the abovecase, the blur in the image of the vehicle 230 is not corrected by theHDR image composition unit 133, while the image having a large blur isdirectly recorded in the normal recording region 173.

It is not sufficient to save the combination image of the long-periodexposure image and the short-period exposure image combined by the HDRimage composition unit 133 directly in the normal recording region 173upon the occurrence of the event. Instead, the captured image data ofthe 360-degree captured images of the long-period exposure image and theshort-period exposure image before being combined by the HDR imagecomposition unit 133 is preferably copied and saved in the eventrecording region 172 upon the occurrence of the event. The sixthembodiment can save the captured image with a smaller blur if an eventsuch as an accident occurs to the vehicle 200.

The vehicle imaging device 100 according to a sixth embodiment may alsostore the image data of the respective directional images combined bythe HDR image composition unit 133 in the ring buffer 171, and copy andsave the image data in the event recording region 172 upon theoccurrence of an event. The vehicle imaging device 100 according to asixth embodiment may be configured so as not to record the respectivedirectional images combined by the HDR image composition unit 133 in thering buffer 171 or the normal recording region 173.

As described above, the imaging unit 12 in the vehicle imaging device100 according to a sixth embodiment generates a long-period exposureimage and a short-period exposure image. The vehicle imaging device 100according to a sixth embodiment includes the image extraction unit 132and the HDR image composition unit 133. The image extraction unit 132generates a front image, a rear image, a right-side image, and aleft-side image based on each of the long-period exposure image and theshort-period exposure image. The HDR image composition unit 133 combinesthe front image 20F, the rear image 20B, the right-side image 20R, andthe left-side image 20L based on each of the long-period exposure imageand the short-period exposure image.

The vehicle imaging device 100 according to a sixth embodiment alsoincludes the ring buffer 171 and the event detection sensor (theacceleration sensor 60). The ring buffer 171 cyclically stores thelong-period exposure image and the short-period exposure image. Theevent detection sensor determines whether any event occurs to thevehicle 200. The controller 16 causes the long-period exposure image andthe short-period exposure image having been stored in the ring buffer171 to be copied and saved in the event recording region 172 when theevent detection sensor determines that an event has occurred to thevehicle 200.

The vehicle imaging device 100 according to a sixth embodiment can savethe captured image with a smaller blur upon an occurrence of an eventsuch as an accident to the vehicle 200.

Seventh Embodiment

A seventh embodiment provides a vehicle imaging device 100 that cangenerate an accurate in-vehicle image. FIG. 23 is a view illustrating a360-degree captured image generated by the imaging unit 12 in a state inwhich the direction of the front image 20F is correctly adjusted to theforward direction of the vehicle 200 through the processing describedwith reference to FIG. 8 and FIG. 9. The in-vehicle image regionincludes an instrument panel including measuring instruments. The imagearound the instrument panel is an essential part in the in-vehicleimage. The vehicle imaging device 100 according to a seventh embodimentexecutes the processing as shown in FIG. 24.

The controller 16 determines whether the front-rear direction of thevehicle imaging device 100 (the vehicle 200) has been defined, andwhether the directions of the front image 20F and the rear image 20Bhave been adjusted in step S71. When the front-rear direction has notbeen defined yet in step S71 (NO), the controller 16 repeats theprocessing in step S71 until the processing as described with referenceto FIG. 8 and FIG. 9 according to a first embodiment is finished.

When the front-rear direction is determined to have been defined in stepS71 (YES), the controller 16 defines an instrument panel region 71 onthe front side of the in-vehicle image region in step S72, asillustrated in FIG. 23. The controller 16 can define a predeterminedregion on the front side of the in-vehicle image region as theinstrument panel region 71. The image analyzer 14 may detect theinstrument panel through image analysis, so that the controller 16defines the instrument panel region 71 in accordance with the detectionresult obtained by the image analyzer 14.

The controller 16 functions as a region setting unit that defines theinstrument panel region 71 and a non-instrument panel region 72 otherthan the instrument panel region 71 in the in-vehicle image region ineach of the long-period exposure image and the short-period exposureimage.

The controller 16 optimizes the in-vehicle image so as to clearly imagethe instrument panel region 71 in step S73. In particular, thecontroller 16 controls the imaging unit 12 to optimize an exposure timewhen generating the long-period exposure image and the short-periodexposure image so as to avoid causing blown-out highlights uponcapturing the image having high brightness displayed with an LED or thelike in the instrument panel region 71.

A first exposure time upon generating the long-period exposure image anda second exposure time upon generating the short-period exposure imageare determined as follows. The first and second exposure times aredefined between a longest time and a shortest time, and are each set toa time between the longest time and the shortest time depending on thebrightness of the image.

A ratio of the first exposure time of the long-period exposure to thesecond exposure time of the short-period exposure is presumed to be10:1, as illustrated in (a) in FIG. 25. A case is presumed in which thecompartment of the vehicle 200 is dark, and a proportion of the optimumexposure time in the non-instrument panel region 72 is 100% of thelongest time, as illustrated in (b) in FIG. 25. A case is presumed inwhich the instrument panel region 71 is brighter than the non-instrumentpanel region 72, and a proportion of the optimum exposure time in theinstrument panel region 71 is 50% of the longest time, as illustrated in(c) in FIG. 25.

When a single image region includes a bright region and a dark region, aproportion of an optimum exposure time is typically determined in viewof an area of the bright region and an area of the dark region. When aratio of the areas between the instrument panel region 71 and thenon-instrument panel region 72 is presumed to be 1:9, the controller 16in this case determines that the proportion of the optimum exposure timein each of the first exposure time of the long-period exposure and thesecond exposure time of the short-period exposure is 95%, as illustratedin (d) in FIG. 25, according to a calculation formula as given by:9/10×100%+ 1/10×50%=95%. However, the instrument panel region 71 wouldcause blown-out highlights if the proportion of the optimum exposuretime is determined to be 95%.

The controller 16 thus desirably determines the proportion of theoptimum exposure time of both the instrument panel region 71 and thenon-instrument panel region 72 in accordance with the proportion of theoptimum exposure time in the instrument panel region 71 that is 50% andthe proportion of the optimum exposure time in the non-instrument panelregion 72 that is 100%. The proportion of the optimum exposure time inthe instrument panel region 71 is referred to as a first optimumexposure-time proportion, and the proportion of the optimum exposuretime in the non-instrument panel region 72 is referred to as a secondoptimum exposure-time proportion. The controller 16 sets a third optimumexposure-time proportion that is a proportion of an exposure time commonto the instrument panel region 71 and the non-instrument panel region71.

The controller 16 in this case does no take account of the ratio of theareas between the instrument panel region 71 and the non-instrumentpanel region 71. As illustrated in (e) in FIG. 25, the controller 16sets 75C which is the average of 50% and 100% as the third optimumexposure-time proportion, for example. Since the exposure time in theinstrument panel region 71 is decreased from 95% to 75%, a probabilityof occurrence of blown-out highlights can be decreased.

While the present embodiment is illustrated above with the case in whichthe non-instrument panel region 72 is darker and the instrument panelregion 71 is brighter, an upper limit of the proportion of the exposuretime in the instrument panel region 71 is desirably set as follows,depending on the relationship of brightness between the instrument panelregion 71 and the non-instrument panel region 72.

A shortest exposure-time proportion under the condition in which theimage in the instrument panel region 71 has no blocked-up shadows isreferred to below as T71S, and a longest exposure-time proportion underthe condition in which the image in the instrument panel region 71 hasno blown-out highlights is referred to below as T71L. An optimumexposure-time proportion in the instrument panel region 71 is referredto below as T71O. An optimum exposure-time proportion in thenon-instrument panel region 72 is referred to below as T72O. Thecontroller 16 can make a decision on the condition of whether blocked-upshadows are caused in the image and the condition of whether blown-outhighlights are caused in the image. The controller 16 can calculate thelongest exposure time and the optimum exposure time that do not lead toblocked-up shadows or blown-out highlights in accordance with thebrightness of the image, so as to determine the respective exposure-timeproportions.

When the compartment is dark, and the instrument panel region 71 isbrighter than the non-instrument panel region 72, the exposure-timeproportions T71S, T71L, T71O, and T72O are respectively 10%, 50%, 30%,and 80%, for example. When the longest exposure-time proportion T71L andthe optimum exposure-time proportion T72O fulfill the relation ofT71L<T72O, the controller 16 desirably controls the imaging unit 12 toset the maximum value of the exposure-time proportion as the longestexposure-time proportion T71L in the instrument panel region 71.

When the compartment is bright due to the irradiation with sunlight, andthe non-instrument panel region 72 is brighter than the instrument panelregion 71, the exposure-time proportions T71S, T71L, T71O, and T72O arerespectively 60%, 80%, 70%, and 20%, for example. When the shortestexposure-time proportion T71S and the optimum exposure-time proportionT72O fulfill the relation of T72O<T71S, the controller 16 desirablycontrols the imaging unit 12 to set the minimum value of theexposure-time proportion as the shortest exposure-time proportion T71Sin the instrument panel region 71.

Controlling the imaging unit 12 by the controller 16 as described aboveavoids blown-out highlights caused in the instrument panel region 71when imaged, and leads the non-instrument panel region 72 to be imagedin a bright state.

The vehicle imaging device 100 according a seventh embodiment thus cangenerate the accurate in-vehicle image.

At least the image processing unit 13, the image analyzer 14, and thecontroller 16 included in the configurations as illustrated in FIG. 2and FIG. 21 may be implemented by a computer or a central processingunit (CPU) of the computer installed in the vehicle imaging device 100,and a computer program (an image processing program) executed by theCPU.

A first embodiment may be an image processing program for causing theCPU to execute the processing as shown in FIG. 8 and FIG. 9. The secondembodiment may be an image processing program for causing the CPU toexecute the processing as shown in FIG. 13. The third embodiment may bean image processing program for executing the CPU to execute theprocessing as shown in FIG. 15. The fourth embodiment may be an imageprocessing program for causing the CPU to execute the processing asshown in FIG. 18A and FIG. 18B. The fifth embodiment may be an imageprocessing program for causing the CPU to execute the processing asshown in FIG. 20A and FIG. 20B. The sixth embodiment may be an imageprocessing program for causing the CPU to execute the processing asshown in FIG. 22. The seventh embodiment may be an image processingprogram for causing the CPU to execute the processing as shown in FIG.24. The respective image processing programs are stored in anon-transitory storage medium.

The present invention is not limited to the above-described first toseventh embodiments, and various modifications can be made within arange without departing from the scope of the present invention. Firstto seventh embodiments may be combined as appropriate within a rangewithout being in consistent with each other. The proper use of hardwareand software are optional.

What is claimed is:
 1. A vehicle imaging device provided in a vehicle,the device comprising: a motion vector detector configured to detectmotion vectors of a captured image of a subject imaged through 360degrees by an imaging unit to which a light enters via a fisheye lens; afront-rear-right-left determination unit configured to determine frontand rear sides and right and left sides of the vehicle in accordancewith the captured image and determine positions of at least a frontimage region and a rear image region in a circumferential direction inthe captured image; an image rotation unit configured to rotate thecaptured image about a first vanishing point of a plurality of radiallydiverging motion vectors among the motion vectors detected by the motionvector detector immediately after the vehicle starts moving, and adjustthe positions of the front image region and the rear image region in thecircumferential direction; and a measurement unit configured to measurea first generation time of the first vanishing point generated in thefront image region and a second generation time of a second vanishingpoint of a plurality of converging motion vectors generated in the frontimage region within a predetermined period of time in a state in whichthe image rotation unit adjusts the positions of the front image regionand the rear image region in the circumferential direction, wherein theimage rotation unit is configured to keep the positions of the frontimage region and the rear image region in the circumferential directionwhen the first generation time measured by the measurement unit islonger than the second generation time, and rotate the captured image toreverse the front image region and the rear image region when the firstgeneration time is not longer than the second generation time, thevehicle imaging device further comprises an image extraction unitconfigured to extract regional images of the front image region and therear image region kept or reversed by the image rotation unit in thecaptured image to generate a front image and a rear image.
 2. Thevehicle imaging device according to claim 1, wherein the image rotationunit rotates the captured image about the first vanishing pint generatedin the regional image newly defined as a front image region afterrotating the captured image to reverse the front image region and therear image region, and adjusts the positions of the front image regionand the rear image region in the circumferential direction.
 3. Thevehicle imaging device according to claim 1, wherein the imageextraction unit corrects a distortion of the extracted front imageregion and rear image region caused by the fisheye lens and generatesthe front image and the rear image so as to approximate the front sideand the rear side of the vehicle that a person is presumed to see. 4.The vehicle imaging device according to claim 1, wherein: thefront-rear-right-left determination unit determines positions of aright-side image region and a left-side image region in thecircumferential direction in the captured image in addition to the frontimage region and the rear image region; the image rotation unit adjuststhe positions of the right-side image region and the left-side imageregion in the circumferential direction in addition to the front imageregion and the rear image region; and the image extraction unit extractsregional images of the right-side image region and the left-side imageregion in the captured image in addition to the front image region andthe rear image region to generate a right-side image and a left-sideimage.
 5. The vehicle imaging device according to claim 1, wherein: theimaging unit generates a long-period exposure image obtained such that asubject is imaged through 360 degrees for a first exposure time, and ashort-period exposure image obtained such that the subject is imagedthrough 360 degrees for a second exposure time shorter than the firstexposure time with the light incident via the fisheye lens; the motionvector detector detects motion vectors of the long-period exposure imageor the short-period exposure image; the image extraction unit extractsregional images of a right-side image region and a left-side imageregion of the vehicle in each of the long-period exposure image and theshort-period exposure image, and generates a right-side image and aleft-side image based on the long-period exposure image and a right-sideimage and a left-side image based on the short-period exposure image;and the vehicle imaging device further comprises a high-dynamic-rangeimage composition unit configured to refer to the motion vectorsdetected in the right-side image region or the left-side image region bythe motion vector detector to combine the right-side image or theleft-side image generated in accordance with the long-period exposureimage with the right-side image or the left-side image generated inaccordance with the short-period exposure image so as to correct a blurof the image of the subject derived from a difference in imaging timingbetween the subject included in the right-side image or the left-sideimage based on the long-period exposure image and the subject includedin the right-side image or the left-side image based on the short-periodexposure image.
 6. The vehicle imaging device according to claim 5,wherein: the image extraction unit extracts regional images of a frontimage region and a rear image region of the vehicle in each of thelong-period exposure image and the short-period exposure image inaddition to the right-side image region and the left-side image regionto generate a front image and a rear image; and the high-dynamic-rangeimage composition unit combines the front image and the rear imagegenerated in accordance with the long-period exposure image with thefront image and the rear image generated in accordance with theshort-period exposure image without referring to the motion vectorsdetected by the motion vector detector.
 7. The vehicle imaging deviceaccording to claim 5, wherein, when the motion vector detector detects aplurality of motion vectors in different directions in the right-sideimage region or the left-side image region, the high-dynamic-range imagecomposition unit refers to the motion vector of the subject included inthe right-side image or the left-side image and determined as acorrection target in accordance with a correction mode preliminarilyset, and combines the right-side image or the left-side image generatedin accordance with the long-period exposure image with the right-sideimage or the left-side image generated in accordance with theshort-period exposure image so as to correct a blur of the image of thesubject as the correction target.
 8. The vehicle imaging deviceaccording to claim 7, wherein: the plurality of motion vectors indifferent directions are a first motion vector in a rearward directionof the vehicle and a second motion vector in a forward direction of thevehicle; when the correction mode corrects the subject as the correctiontarget relatively shifting in the rearward direction of the vehicle, thehigh-dynamic-range image composition unit refers to the first motionvector to combine the right-side image or the left-side image generatedin accordance with the long-period exposure image with the right-sideimage or the left-side image generated in accordance with theshort-period exposure image; and when the correction mode corrects thesubject as the correction target relatively shifting in the forwarddirection of the vehicle, the high-dynamic-range image composition unitrefers to the second motion vector to combine the right-side image orthe left-side image generated in accordance with the long-periodexposure image with the right-side image or the left-side imagegenerated in accordance with the short-period exposure image.
 9. Thevehicle imaging device according to claim 8, wherein, when a pluralityof subjects are present in the right-side image or the left-side image,and the correction mode corrects the subject as the correction targetcloser to the vehicle, the high-dynamic-range image composition unitrefers to the first motion vector or the second motion vectorcorresponding to a direction in which the subject closer to the vehicleis shifting, and combines the right-side image or the left-side imagegenerated in accordance with the long-period exposure image with theright-side image or the left-side image generated in accordance with theshort-period exposure image.
 10. The vehicle imaging device according toclaim 8, wherein, when a first subject relatively shifting in therearward direction of the vehicle and a second subject relativelyshifting in the forward direction of the vehicle are present in theright-side image or the left-side image, and the correction modecorrects the subject as the correction target determined in accordancewith a proportion of an area of the second subject in the right-sideimage or the left-side image, the high-dynamic-range image compositionunit refers to the first motion vector when the proportion of the areaof the second subject is not a predetermined proportion or greater inthe right-side image or the left-side image, and combines the right-sideimage or the left-side image generated in accordance with thelong-period exposure image with the right-side image or the left-sideimage generated in accordance with the short-period exposure image, andthe high-dynamic-range image composition unit refers to the secondmotion vector when the proportion of the area of the second subject isthe predetermined proportion or greater in the right-side image or theleft-side image, and combines the right-side image or the left-sideimage generated in accordance with the long-period exposure image withthe right-side image or the left-side image generated in accordance withthe short-period exposure image.
 11. The vehicle imaging deviceaccording to claim 1, wherein: the imaging unit generates a long-periodexposure image obtained such that a subject is imaged through 360degrees for a first exposure time, and a short-period exposure imageobtained such that the subject is imaged through 360 degrees for asecond exposure time shorter than the first exposure time with the lightincident via the fisheye lens; the front-rear-right-left determinationunit determines the front and rear sides and the right and left sides ofthe vehicle in accordance with the long-period exposure image and theshort-period exposure image, and determines positions of a front imageregion, a rear image region, a right-side image region, and a left-sideimage region in the circumferential direction in each of the long-periodexposure image and the short-period exposure image; the image extractionunit extracts regional images of the front image region, the rear imageregion, the right-side image region, and the left-side image region ineach of the long-period exposure image and the short-period exposureimage, and generates directional images of a front image, a rear image,a right-side image, and a left-side image; the vehicle imaging devicefurther comprises a high-dynamic-range image composition unit configuredto combine the front image, the rear image, the right-side image, andthe left-side image based on the long-period exposure image generated bythe image extraction unit with the front image, the rear image, theright-side image, and the left-side image based on the short-periodexposure image generated by the image extraction unit, and a sunlightincident-direction determination unit configured to determine anincident direction of sunlight entering the vehicle imaging device; andthe high-dynamic-range image composition unit sets a ratio of thedirectional image based on the long-period exposure image chosen fromthe front image, the rear image, the right-side image, and the left-sideimage in accordance with the incident direction of the sunlightdetermined by the sunlight incident-direction determination unit to begreater than a ratio of the other directional images based on thelong-period exposure image not chosen.
 12. The vehicle imaging deviceaccording to claim 11, wherein: the sunlight incident-directiondetermination unit divides a 360-degree direction imaged by the vehicleimaging device into a plurality of directions including at least a frontdirection, a rear direction, a right direction, and a left direction,and determines which is the incident direction of the sunlight; thehigh-dynamic-range image composition unit increases the ratio of thefront image based on the long-period exposure image when the incidentdirection of the sunlight is the front direction; increases the ratio ofthe rear image based on the long-period exposure image when the incidentdirection of the sunlight is the rear direction; increases the ratio ofthe right-side image based on the long-period exposure image when theincident direction of the sunlight is the right direction; and increasesthe ratio of the left-side image based on the long-period exposure imagewhen the incident direction of the sunlight is the left direction. 13.The vehicle imaging device according to claim 12, wherein: the sunlightincident-direction determination unit divides the 360-degree directionimaged by the vehicle imaging device into a plurality of directionsincluding a front-right direction, a rear-right direction, a rear-leftdirection, and a front-left direction, in addition to the frontdirection, the rear direction, the right direction, and the leftdirection, and determines which is the incident direction of thesunlight; the high-dynamic-range image composition unit increases theratio of each of the front image and the right-side image based on thelong-period exposure image when the incident direction of the sunlightis the front-right direction; increases the ratio of each of the rearimage and the right-side image based on the long-period exposure imagewhen the incident direction of the sunlight is the rear-right direction;increases the ratio of each of the rear image and the left-side imagebased on the long-period exposure image when the incident direction ofthe sunlight is the rear-left direction; and increases the ratio of eachof the front image and the left-side image based on the long-periodexposure image when the incident direction of the sunlight is thefront-left direction.
 14. The vehicle imaging device according to claim1, wherein: the imaging unit generates a long-period exposure imageobtained such that a subject is imaged through 360 degrees for a firstexposure time, and a short-period exposure image obtained such that thesubject is imaged through 360 degrees for a second exposure time shorterthan the first exposure time with the light incident via the fisheyelens; the front-rear-right-left determination unit determines the frontand rear sides and the right and left sides of the vehicle in accordancewith the long-period exposure image and the short-period exposure image,and determines positions of a front image region, a rear image region, aright-side image region, and a left-side image region in thecircumferential direction in each of the long-period exposure image andthe short-period exposure image; the image extraction unit extractsregional images of the front image region, the rear image region, theright-side image region, and the left-side image region in each of thelong-period exposure image and the short-period exposure image, andgenerates directional images of a front image, a rear image, aright-side image, and a left-side image; the vehicle imaging devicefurther comprises a high-dynamic-range image composition unit configuredto combine the directional images of the front image, the rear image,the right-side image, and the left-side image based on the long-periodexposure image generated by the image extraction unit with thedirectional images of the front image, the rear image, the right-sideimage, and the left-side image based on the short-period exposure imagegenerated by the image extraction unit, and a tunnel travellingdetermination unit configured to determine a state of the travelingvehicle when coming closer to a tunnel, entering the tunnel andtraveling in the tunnel, and coming out of the tunnel; and thehigh-dynamic-range image composition unit adjusts a ratio of thedirectional image based on the long-period exposure image or a ratio ofthe directional image based on the short-period exposure image chosenfrom the front image, the rear image, the right-side image, and theleft-side image in accordance with a position of the vehicle beforeentering the tunnel, during traveling in the tunnel, and after comingout of the tunnel according to a determination made by the tunneltravelling determination unit.
 15. The vehicle imaging device accordingto claim 14, wherein the high-dynamic-range image composition unitincreases the ratio of the front image based on the long-period exposureimage when the tunnel travelling determination unit determines that thevehicle is coming closer to the tunnel and an image inside the tunnel isa predetermined proportion or greater in the front image.
 16. Thevehicle imaging device according to claim 14, wherein thehigh-dynamic-range image composition unit increases the ratio of each ofthe right-side image and the left-side image based on the long-periodexposure image when the tunnel travelling determination unit determinesthat the vehicle enters tunnel.
 17. The vehicle imaging device accordingto claim 14, wherein the high-dynamic-range image composition unitincreases the ratio of the rear image based on the long-period exposureimage when the tunnel travelling determination unit determines that animage excluding the tunnel toward an entrance of the tunnel after thevehicle enters the tunnel is a predetermined proportion or less in therear image.
 18. The vehicle imaging device according to claim 14,wherein the high-dynamic-range image composition unit decreases theratio of the front image based on the long-period exposure image whenthe tunnel travelling determination unit determines that the vehicle iscoming closer to an exit of the tunnel and an image excluding the tunneltoward the exit of the tunnel is a predetermined proportion or greaterin the front image.
 19. The vehicle imaging device according to claim14, wherein the high-dynamic-range image composition unit decreases theratio of each of the right-side image and the left-side image based onthe long-period exposure image when the tunnel travelling determinationunit determines that the vehicle comes out of the tunnel.
 20. Thevehicle imaging device according to claim 1, wherein: the imaging unitgenerates a long-period exposure image obtained such that a subject isimaged through 360 degrees for a first exposure time, and a short-periodexposure image obtained such that the subject is imaged through 360degrees for a second exposure time shorter than the first exposure timewith the light incident via the fisheye lens; the image extraction unitextracts regional images of a front image region, a rear image region, aright-side image region, and a left-side image region of the vehicle ineach of the long-period exposure image and the short-period exposureimage, and generates directional images of a front image, a rear image,a right-side image, and a left-side image based on the long-periodexposure image and directional images of a front image, a rear image, aright-side image, and a left-side image based on the short-periodexposure image; and the vehicle imaging device further comprises ahigh-dynamic-range image composition unit configured to combine therespective directional images based on the long-period exposure imagewith the respective directional images based on the short-periodexposure image, a ring buffer configured to cyclically store thelong-period exposure image and the short-period exposure image, an eventdetection sensor configured to determine whether an event occurs to thevehicle, and a controller configured to control to copy and save thelong-period exposure image and the short-period exposure image stored inthe ring buffer to an event recording region when the event detectionsensor determines that the event occurs to the vehicle.
 21. The vehicleimaging device according to claim 20, wherein the controller controls torecord a combined image of the respective directional images based onthe long-period exposure image and the respective directional imagesbased on the short-period exposure image generated by thehigh-dynamic-range image composition unit in a normal recording regionwithout recording in the ring buffer.
 22. The vehicle imaging deviceaccording to claim 20, wherein the controller is configured to: store acombined image of the respective directional images based on thelong-period exposure image and the respective directional images basedon the short-period exposure image generated by the high-dynamic-rangeimage composition unit in the ring buffer; and control to copy and savethe combined image stored in the ring buffer to the event recordingregion when the event detection sensor determines that the event occursto the vehicle.
 23. The vehicle imaging device according to claim 1,wherein: the imaging unit generates a long-period exposure imageobtained such that a subject is imaged through 360 degrees for a firstexposure time, and a short-period exposure image obtained such that thesubject is imaged through 360 degrees for a second exposure time shorterthan the first exposure time with the light incident via the fisheyelens; and the vehicle imaging device further comprises ahigh-dynamic-range image composition unit configured to combine thelong-period exposure image with the short-period exposure image in apredetermined ratio, a region setting unit configured to define aninstrument panel region including an instrument panel of the vehicle anda non-instrument panel region other than the instrument panel region inan in-vehicle image region of the vehicle in each of the long-periodexposure image and the short-period exposure image, and a controllerconfigured to, when a proportion of an optimum exposure timecorresponding to a brightness of an image in the instrument panel regionto a longest exposure time of each of the long-period exposure image andthe short-period exposure image is defined as a first optimumexposure-time proportion, and a proportion of an optimum exposure timecorresponding to a brightness of an image in the non-instrument panelregion to the longest exposure time of each of the long-period exposureimage and the short-period exposure image is defined as a second optimumexposure-time proportion, control the imaging unit to set a thirdoptimum exposure-time proportion common to the instrument panel regionand the non-instrument panel region in accordance with the first optimumexposure-time proportion and the second optimum exposure-time proportionwithout taking account of a ratio of areas between the instrument panelregion and the non-instrument panel region.
 24. The vehicle imagingdevice according to claim 23, wherein the controller is configured to:determine whether an image has blown-out highlights; and when the secondoptimum exposure-time proportion is greater than a longest exposure-timeproportion under a condition in which the image in the instrument panelregion has no blown-out highlights, control the imaging unit to set amaximum value of an exposure-time proportion as the longestexposure-time proportion in the instrument panel region.
 25. The vehicleimaging device according to claim 23, wherein the controller isconfigured to: determine whether an image has blocked-up shadows; andwhen a shortest exposure-time proportion under a condition in which theimage in the instrument panel region has no blocked-up shadows isgreater than the second optimum exposure-time proportion, control theimaging unit to set a minimum value of an exposure-time proportion asthe shortest exposure-time proportion in the instrument panel region.26. An image processing method for a vehicle imaging device provided ina vehicle, the method comprising: detecting motion vectors of a capturedimage of a subject imaged through 360 degrees by an imaging unit towhich a light enters via a fisheye lens; determining front and rearsides and right and left sides of the vehicle in accordance with thecaptured image and determining positions of at least a front imageregion and a rear image region in a circumferential direction in thecaptured image; rotating the captured image about a first vanishingpoint of a plurality of radially diverging motion vectors among themotion vectors detected immediately after the vehicle starts moving, andadjusting the positions of the front image region and the rear imageregion in the circumferential direction; measuring a first generationtime of the first vanishing point generated in the front image regionand a second generation time of a second vanishing point of a pluralityof converging motion vectors generated in the front image region withina predetermined period of time in a state of adjusting the positions ofthe front image region and the rear image region in the circumferentialdirection; keeping the positions of the front image region and the rearimage region in the circumferential direction when the first generationtime measured is longer than the second generation time; rotating thecaptured image to reverse the front image region and the rear imageregion when the first generation time measured is not longer than thesecond generation time; and extracting regional images of the frontimage region and the rear image region kept when the first generationtime measured is longer than the second generation time or reversed whenthe first generation time measured is not longer than the secondgeneration time in the captured image to generate a front image and arear image.
 27. An image processing program stored in a non-transitorystorage medium causing a computer installed in a vehicle imaging deviceprovided in a vehicle to execute the steps of: detecting motion vectorsof a captured image of a subject imaged through 360 degrees by animaging unit to which a light enters via a fisheye lens; determiningfront and rear sides and right and left sides of the vehicle inaccordance with the captured image and determining positions of at leasta front image region and a rear image region in a circumferentialdirection in the captured image; rotating the captured image about afirst vanishing point of a plurality of radially diverging motionvectors among the motion vectors detected immediately after the vehiclestarts moving, and adjusting the positions of the front image region andthe rear image region in the circumferential direction; measuring afirst generation time of the first vanishing point generated in thefront image region and a second generation time of a second vanishingpoint of a plurality of converging motion vectors generated in the frontimage region within a predetermined period of time in a state ofadjusting the positions of the front image region and the rear imageregion in the circumferential direction; keeping the positions of thefront image region and the rear image region in the circumferentialdirection when the first generation time measured is longer than thesecond generation time; rotating the captured image to reverse the frontimage region and the rear image region when the first generation timemeasured is not longer than the second generation time; and extractingregional images of the front image region and the rear image region keptwhen the first generation time measured is longer than the secondgeneration time or reversed when the first generation time measured isnot longer than the second generation time in the captured image togenerate a front image and a rear image.